diff options
author | Christopher Faylor <me@cgf.cx> | 2002-03-07 01:31:08 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2002-03-07 01:31:08 +0000 |
commit | 9420d2b833b90df94e425b84b17b49735e1caa39 (patch) | |
tree | bee976e4bf6b5e40c72c504f90eda7a9d13ea15d | |
parent | 2a606041a1d6e841ebe7c3158e12bd6d6ad1b51e (diff) | |
download | cygnal-9420d2b833b90df94e425b84b17b49735e1caa39.tar.gz cygnal-9420d2b833b90df94e425b84b17b49735e1caa39.tar.bz2 cygnal-9420d2b833b90df94e425b84b17b49735e1caa39.zip |
* path.cc (normalize_posix_path): Avoid runs of '.'s > 2.
-rw-r--r-- | winsup/cygwin/ChangeLog | 4 | ||||
-rw-r--r-- | winsup/cygwin/path.cc | 6 |
2 files changed, 9 insertions, 1 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index ef02345a9..a8e45ab48 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,7 @@ +2002-03-06 Christopher Faylor <cgf@redhat.com> + + * path.cc (normalize_posix_path): Avoid runs of '.'s > 2. + 2002-03-05 Christopher Faylor <cgf@redhat.com> * errno.cc: Change EPERM associated text to "Operation not permitted" diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc index 01798209f..e95f6caf1 100644 --- a/winsup/cygwin/path.cc +++ b/winsup/cygwin/path.cc @@ -249,7 +249,11 @@ normalize_posix_path (const char *src, char *dst) break; } else if (src[2] && !isslash (src[2])) - break; + { + if (src[2] == '.') + return ENOENT; + break; + } else { while (dst > dst_start && !isslash (*--dst)) |