You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by bj...@apache.org on 2005/06/29 13:46:34 UTC
svn commit: r202350 - /apr/apr/branches/1.1.x/file_io/os2/open.c
Author: bjh
Date: Wed Jun 29 04:46:34 2005
New Revision: 202350
URL: http://svn.apache.org/viewcvs?rev=202350&view=rev
Log:
OS/2: Using apr_file_rename() to replace one file with another doesn't work
on some types of network drive as the file system driver returns a different
error code when an attempt is made to rename to an existing file name.
Allow for this error code, ERROR_ALREADY_EXISTS.
Modified:
apr/apr/branches/1.1.x/file_io/os2/open.c
Modified: apr/apr/branches/1.1.x/file_io/os2/open.c
URL: http://svn.apache.org/viewcvs/apr/apr/branches/1.1.x/file_io/os2/open.c?rev=202350&r1=202349&r2=202350&view=diff
==============================================================================
--- apr/apr/branches/1.1.x/file_io/os2/open.c (original)
+++ apr/apr/branches/1.1.x/file_io/os2/open.c Wed Jun 29 04:46:34 2005
@@ -158,7 +158,7 @@
{
ULONG rc = DosMove(from_path, to_path);
- if (rc == ERROR_ACCESS_DENIED) {
+ if (rc == ERROR_ACCESS_DENIED || rc == ERROR_ALREADY_EXISTS) {
rc = DosDelete(to_path);
if (rc == 0 || rc == ERROR_FILE_NOT_FOUND) {