summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Kjetil Barvik <barvik@broadpark.no>2009-06-14 15:08:28 +0200
committerLibravatar Junio C Hamano <gitster@pobox.com>2009-07-29 20:20:12 -0700
commit77716755cbdf970fa0814a5f77c884b1f17693de (patch)
tree7ea6ab124233dafe0d1d9a894e298fc9a1e51f5c /t
parentDemonstrate bugs when a directory is replaced with a symlink (diff)
downloadtgif-77716755cbdf970fa0814a5f77c884b1f17693de.tar.xz
lstat_cache: guard against full match of length of 'name' parameter
longest_path_match() in symlinks.c does exactly what it's name says, but in some cases that match can be too long, since the has_*_leading_path() functions assumes that the match will newer be as long as the name string given to the function. fix this by adding an extra if test which checks if the match length is equal to the 'len' parameter. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-xt/t6035-merge-dir-to-symlink.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t6035-merge-dir-to-symlink.sh b/t/t6035-merge-dir-to-symlink.sh
index 18d5f9454b..ba90fc53e0 100755
--- a/t/t6035-merge-dir-to-symlink.sh
+++ b/t/t6035-merge-dir-to-symlink.sh
@@ -26,7 +26,7 @@ test_expect_failure 'keep a/b-2/c/d across checkout' '
test -f a/b-2/c/d
'
-test_expect_failure 'checkout should not have deleted a/b-2/c/d' '
+test_expect_success 'checkout should not have deleted a/b-2/c/d' '
git checkout HEAD^0 &&
git reset --hard master &&
git checkout start^0 &&