]> rtime.felk.cvut.cz Git - git.git/blobdiff - gitweb/gitweb.perl
gitweb: Better regexp for SHA-1 committag match
[git.git] / gitweb / gitweb.perl
index f27dbb6bf4acfe6f5381d7c86760b1170c8a10ff..bec1af6b73bca92fdb0cabc45bb5e41d178b9a1d 100755 (executable)
@@ -1364,7 +1364,7 @@ sub format_log_line_html {
        my $line = shift;
 
        $line = esc_html($line, -nbsp=>1);
-       if ($line =~ m/([0-9a-fA-F]{8,40})/) {
+       if ($line =~ m/\b([0-9a-fA-F]{8,40})\b/) {
                my $hash_text = $1;
                my $link =
                        $cgi->a({-href => href(action=>"object", hash=>$hash_text),