From 242d23e9a39fcde3370290588511ffe7d8c8a029 Mon Sep 17 00:00:00 2001 From: Marcus Meissner Date: Mon, 21 Aug 2000 03:18:32 +0000 Subject: [PATCH] (from IBM TopPage patch) return correct error for already existing file. --- files/file.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/files/file.c b/files/file.c index e85f4b3b97a..1252f0b198c 100644 --- a/files/file.c +++ b/files/file.c @@ -1762,9 +1762,11 @@ BOOL WINAPI MoveFileA( LPCSTR fn1, LPCSTR fn2 ) TRACE("(%s,%s)\n", fn1, fn2 ); if (!DOSFS_GetFullName( fn1, TRUE, &full_name1 )) return FALSE; - if (DOSFS_GetFullName( fn2, TRUE, &full_name2 )) + if (DOSFS_GetFullName( fn2, TRUE, &full_name2 )) { /* The new name must not already exist */ + SetLastError(ERROR_ALREADY_EXISTS); return FALSE; + } if (!DOSFS_GetFullName( fn2, FALSE, &full_name2 )) return FALSE; if (full_name1.drive == full_name2.drive) /* move */ -- 2.11.4.GIT