summaryrefslogtreecommitdiff
path: root/t/t6008-rev-list-submodule.sh
diff options
context:
space:
mode:
authorLibravatar Jakub Narebski <jnareb@gmail.com>2008-04-13 14:12:15 +0200
committerLibravatar Junio C Hamano <gitster@pobox.com>2008-04-18 22:10:38 -0700
commit5634cf24766f8700804ca55f5e8567c88538a5b0 (patch)
tree2b72e937b347123e0c513d5ec25a40a3734c9eef /t/t6008-rev-list-submodule.sh
parentDocument that WebDAV doesn't need git on the server, and works over SSL (diff)
downloadtgif-5634cf24766f8700804ca55f5e8567c88538a5b0.tar.xz
gitweb: Fix 'history' view for deleted files with history
When asked for history of a file which is not present in given branch ("HEAD", i.e. current branch, or given by transient $hash_hase ('hb') parameter), but is present deeper in the history (meaning that "git rev-list --full-history $hash_base -- $file_name" is not empty), and there is no $hash ('h') parameter set for a file, gitweb would spew multiple of "Use of uninitialized value" warnings, and some links would be missing. This commit fixes this bug. This bug occurs in the rare cases when "git log -- <path>" is empty and "git log --full-history -- <path>" is not, or to be more exact in the cases when full-history starts later than given branch. It can happen if you are using handcrafted gitwb URL, or if you follow generic 'history' link or bookmark for a file which got deleted. Gitweb tried to get file type ('tree', or 'blob', or even 'commit') from the commit we start searching from (where the file was not present), and not among found commits. This was the cause of "Use of uninitialized value" warnings. This commit also add tests for such situation to t9500 test. While we are it, return HTTP error if there is _no_ history; it means that file or directory was not found (for given branch). Also error out if type of item could not be found: it should not happen now, but better be sure. Signed-off-by: Jakub Narebski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t6008-rev-list-submodule.sh')
0 files changed, 0 insertions, 0 deletions