diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2013-07-18 10:11:33 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2013-07-18 10:11:33 +0000 |
commit | aff6ef0db4767fd53eb69ea2f573ec4c8ae7c5a6 (patch) | |
tree | a0398a026fcc69885da1864860d0f9fe5b56bfd2 /winsup | |
parent | e6f4f3f7eedd355d78f1751e724731a7842bc7db (diff) | |
download | newlib-aff6ef0db4767fd53eb69ea2f573ec4c8ae7c5a6.zip newlib-aff6ef0db4767fd53eb69ea2f573ec4c8ae7c5a6.tar.gz newlib-aff6ef0db4767fd53eb69ea2f573ec4c8ae7c5a6.tar.bz2 |
* path.cc (normalize_posix_path): Start checking path before ".." at
dst, rather than at dst_start, otherwise suffer loss of one leading
slash in case of UNC paths.
Diffstat (limited to 'winsup')
-rw-r--r-- | winsup/cygwin/ChangeLog | 6 | ||||
-rw-r--r-- | winsup/cygwin/path.cc | 4 |
2 files changed, 8 insertions, 2 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 41d94b9..a003cf0 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,9 @@ +2013-07-18 Corinna Vinschen <corinna@vinschen.de> + + * path.cc (normalize_posix_path): Start checking path before ".." at + dst, rather than at dst_start, otherwise suffer loss of one leading + slash in case of UNC paths. + 2013-07-17 Christopher Faylor <me.cygwin2013@cgf.cx> * winsup.h (cygbench): Fix declaration to match definition. diff --git a/winsup/cygwin/path.cc b/winsup/cygwin/path.cc index 6c9bc23..7f0e5b8 100644 --- a/winsup/cygwin/path.cc +++ b/winsup/cygwin/path.cc @@ -312,8 +312,8 @@ normalize_posix_path (const char *src, char *dst, char *&tail) if (check_parent) { *tail = 0; - debug_printf ("checking %s before '..'", dst_start); - path_conv head (dst_start); + debug_printf ("checking %s before '..'", dst); + path_conv head (dst); if (!head.isdir()) return ENOENT; check_parent = false; |