Merge branch 'ad/cygwin-no-backslashes-in-paths'
Cygwin pathname handling fix. * ad/cygwin-no-backslashes-in-paths: cygwin: disallow backslashes in file namesmaint
commit
bb2feec17f
|
@ -1011,7 +1011,7 @@ inside:
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (protect_ntfs) {
|
if (protect_ntfs) {
|
||||||
#ifdef GIT_WINDOWS_NATIVE
|
#if defined GIT_WINDOWS_NATIVE || defined __CYGWIN__
|
||||||
if (c == '\\')
|
if (c == '\\')
|
||||||
return 0;
|
return 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -191,7 +191,7 @@ test_expect_success 'fsck detects corrupt .gitmodules' '
|
||||||
)
|
)
|
||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success MINGW 'prevent git~1 squatting on Windows' '
|
test_expect_success WINDOWS 'prevent git~1 squatting on Windows' '
|
||||||
git init squatting &&
|
git init squatting &&
|
||||||
(
|
(
|
||||||
cd squatting &&
|
cd squatting &&
|
||||||
|
@ -219,10 +219,13 @@ test_expect_success MINGW 'prevent git~1 squatting on Windows' '
|
||||||
test_tick &&
|
test_tick &&
|
||||||
git -c core.protectNTFS=false commit -m "module"
|
git -c core.protectNTFS=false commit -m "module"
|
||||||
) &&
|
) &&
|
||||||
|
if test_have_prereq MINGW
|
||||||
|
then
|
||||||
test_must_fail git -c core.protectNTFS=false \
|
test_must_fail git -c core.protectNTFS=false \
|
||||||
clone --recurse-submodules squatting squatting-clone 2>err &&
|
clone --recurse-submodules squatting squatting-clone 2>err &&
|
||||||
test_i18ngrep -e "directory not empty" -e "not an empty directory" err &&
|
test_i18ngrep -e "directory not empty" -e "not an empty directory" err &&
|
||||||
! grep gitdir squatting-clone/d/a/git~2
|
! grep gitdir squatting-clone/d/a/git~2
|
||||||
|
fi
|
||||||
'
|
'
|
||||||
|
|
||||||
test_expect_success 'git dirs of sibling submodules must not be nested' '
|
test_expect_success 'git dirs of sibling submodules must not be nested' '
|
||||||
|
|
|
@ -1459,6 +1459,7 @@ case $uname_s in
|
||||||
test_set_prereq NATIVE_CRLF
|
test_set_prereq NATIVE_CRLF
|
||||||
test_set_prereq SED_STRIPS_CR
|
test_set_prereq SED_STRIPS_CR
|
||||||
test_set_prereq GREP_STRIPS_CR
|
test_set_prereq GREP_STRIPS_CR
|
||||||
|
test_set_prereq WINDOWS
|
||||||
GIT_TEST_CMP=mingw_test_cmp
|
GIT_TEST_CMP=mingw_test_cmp
|
||||||
;;
|
;;
|
||||||
*CYGWIN*)
|
*CYGWIN*)
|
||||||
|
@ -1467,6 +1468,7 @@ case $uname_s in
|
||||||
test_set_prereq CYGWIN
|
test_set_prereq CYGWIN
|
||||||
test_set_prereq SED_STRIPS_CR
|
test_set_prereq SED_STRIPS_CR
|
||||||
test_set_prereq GREP_STRIPS_CR
|
test_set_prereq GREP_STRIPS_CR
|
||||||
|
test_set_prereq WINDOWS
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
test_set_prereq POSIXPERM
|
test_set_prereq POSIXPERM
|
||||||
|
|
Loading…
Reference in New Issue