diff options
author | Timo Hirvonen <tihirvon@gmail.com> | 2006-06-20 16:41:05 +0300 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-06-22 02:23:12 -0700 |
commit | 4c5c20261c5403650a31a91ebce0cc9444182383 (patch) | |
tree | 569dce9b9225a2a88a5b79070be339a927c3b928 /gitweb/gitweb.cgi | |
parent | gitweb: Make use of $PATH_INFO for project parameter (diff) | |
download | tgif-4c5c20261c5403650a31a91ebce0cc9444182383.tar.xz |
gitweb: Use $hash_base as $search_hash if possible
$hash (h parameter) does not always point to a commit. Use $hash_base as
$search_hash when it is defined.
Signed-off-by: Timo Hirvonen <tihirvon@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'gitweb/gitweb.cgi')
-rwxr-xr-x | gitweb/gitweb.cgi | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/gitweb/gitweb.cgi b/gitweb/gitweb.cgi index f2e50462d9..e2108dee7c 100755 --- a/gitweb/gitweb.cgi +++ b/gitweb/gitweb.cgi @@ -322,7 +322,9 @@ EOF $searchtext = ""; } my $search_hash; - if (defined $hash) { + if (defined $hash_base) { + $search_hash = $hash_base; + } elsif (defined $hash) { $search_hash = $hash; } else { $search_hash = "HEAD"; |