diff options
author | Corinna Vinschen <corinna@vinschen.de> | 2000-05-22 17:15:47 +0000 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2000-05-22 17:15:47 +0000 |
commit | 689221682269bf5c40567d15d28bfb73369253e7 (patch) | |
tree | a13f3a2b3f90ea1071d94f8920dd3f5727272ee0 /winsup/cygwin/syscalls.cc | |
parent | 7054be8b55c2f06303b0b9111dabba0ca8abe999 (diff) | |
download | cygnal-689221682269bf5c40567d15d28bfb73369253e7.tar.gz cygnal-689221682269bf5c40567d15d28bfb73369253e7.tar.bz2 cygnal-689221682269bf5c40567d15d28bfb73369253e7.zip |
* dir.cc (rmdir): Care for misleading error messages
when trying to remove a directory on a samba share.
Eliminate superfluous else branch.
* syscalls.cc (_rename): Additional check for ERROR_FILE_EXISTS
if MoveFile fails.
Diffstat (limited to 'winsup/cygwin/syscalls.cc')
-rw-r--r-- | winsup/cygwin/syscalls.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc index c1ad04b1c..e6a5c0670 100644 --- a/winsup/cygwin/syscalls.cc +++ b/winsup/cygwin/syscalls.cc @@ -1231,7 +1231,8 @@ _rename (const char *oldpath, const char *newpath) if (!MoveFile (real_old.get_win32 (), real_new.get_win32 ())) res = -1; - if (res == 0 || GetLastError () != ERROR_ALREADY_EXISTS) + if (res == 0 || (GetLastError () != ERROR_ALREADY_EXISTS + && GetLastError () != ERROR_FILE_EXISTS)) goto done; if (os_being_run == winNT) |