Skip to content

Commit

Permalink
Check for the existence of the file that could be a POSIX filepath
Browse files Browse the repository at this point in the history
Under cygwin, if you pass a path like /c/cygdrive/, we check that
/c exists and is a directory.

If you have files in the root of the cygwin environment and you pass
/ROOTFILE, we need to weaken the check so that we only check that
the file exists. We don't care that it's not a directory.

(cherry picked from commit 0717c66)
  • Loading branch information
big-guy authored and ljacomet committed Dec 20, 2021
1 parent 1785906 commit 94ce723
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -210,7 +210,7 @@ if "\$cygwin" || "\$msys" ; then
case \$arg in #(
-*) false ;; # don't mess with options #(
/?*) t=\${arg#/} t=/\${t%%/*} # looks like a POSIX filepath
[ -d "\$t" ] ;; #(
[ -e "\$t" ] ;; #(
*) false ;;
esac
then
Expand Down

0 comments on commit 94ce723

Please sign in to comment.