* cygpath.cc (do_pathconv): Fix erroneously printing native NT path

prefix introduced by previous patch.
This commit is contained in:
Corinna Vinschen 2010-02-22 17:40:46 +00:00
parent f2ecf0ee5b
commit 80206d7f71
2 changed files with 8 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2010-02-22 Corinna Vinschen <corinna@vinschen.de>
* cygpath.cc (do_pathconv): Fix erroneously printing native NT path
prefix introduced by previous patch.
2010-02-22 Corinna Vinschen <corinna@vinschen.de> 2010-02-22 Corinna Vinschen <corinna@vinschen.de>
* locale.cc (lc_time_names): Add "date_fmt" entry. * locale.cc (lc_time_names): Add "date_fmt" entry.

View File

@ -687,6 +687,7 @@ do_pathconv (char *filename)
wchar_t *buf2 = NULL; wchar_t *buf2 = NULL;
DWORD len; DWORD len;
ssize_t err; ssize_t err;
bool print_tmp = false;
cygwin_conv_path_t conv_func = cygwin_conv_path_t conv_func =
(unix_flag ? CCP_WIN_A_TO_POSIX (unix_flag ? CCP_WIN_A_TO_POSIX
: (path_flag ? CCP_POSIX_TO_WIN_A : (path_flag ? CCP_POSIX_TO_WIN_A
@ -783,6 +784,7 @@ do_pathconv (char *filename)
tmp += len; tmp += len;
if (len == 6) if (len == 6)
*tmp = '\\'; *tmp = '\\';
print_tmp = true;
} }
} }
if (mixed_flag) if (mixed_flag)
@ -790,7 +792,7 @@ do_pathconv (char *filename)
} }
} }
puts (buf); puts (print_tmp ? tmp : buf);
if (buf2) if (buf2)
free (buf2); free (buf2);
if (buf) if (buf)