From c019f5356858f1c29a914e07d85b97304066a941 Mon Sep 17 00:00:00 2001 From: Alberto Massari Date: Thu, 2 Jan 2003 19:24:42 +0000 Subject: [PATCH] Add stub implementation for ReplaceFile. --- dlls/kernel/kernel32.spec | 6 +++--- files/file.c | 27 +++++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 3 deletions(-) diff --git a/dlls/kernel/kernel32.spec b/dlls/kernel/kernel32.spec index 279857b1ee9..d892f80df99 100644 --- a/dlls/kernel/kernel32.spec +++ b/dlls/kernel/kernel32.spec @@ -685,9 +685,9 @@ @ stdcall ReinitializeCriticalSection(ptr) ReinitializeCriticalSection @ stdcall ReleaseMutex(long) ReleaseMutex @ stdcall ReleaseSemaphore(long long ptr) ReleaseSemaphore -@ stub ReplaceFile -@ stub ReplaceFileA -@ stub ReplaceFileW +@ stdcall ReplaceFile(wstr wstr wstr long ptr ptr) ReplaceFileW +@ stdcall ReplaceFileA(str str str long ptr ptr) ReplaceFileA +@ stdcall ReplaceFileW(wstr wstr wstr long ptr ptr) ReplaceFileW @ stdcall RemoveDirectoryA(str) RemoveDirectoryA @ stdcall RemoveDirectoryW(wstr) RemoveDirectoryW @ stub RequestDeviceWakeup diff --git a/files/file.c b/files/file.c index d14a04d763b..0031281423b 100644 --- a/files/file.c +++ b/files/file.c @@ -3409,3 +3409,30 @@ BOOL WINAPI GetFileAttributesExA( SetLastError(ERROR_NOT_ENOUGH_MEMORY); return ret; } + +/************************************************************************** + * ReplaceFileW (KERNEL32.@) + * ReplaceFile (KERNEL32.@) + */ +BOOL WINAPI ReplaceFileW(LPCWSTR lpReplacedFileName,LPCWSTR lpReplacementFileName, + LPCWSTR lpBackupFileName, DWORD dwReplaceFlags, + LPVOID lpExclude, LPVOID lpReserved) +{ + FIXME("(%s,%s,%s,%08lx,%p,%p) stub\n",debugstr_w(lpReplacedFileName),debugstr_w(lpReplacementFileName), + debugstr_w(lpBackupFileName),dwReplaceFlags,lpExclude,lpReserved); + SetLastError(ERROR_UNABLE_TO_MOVE_REPLACEMENT); + return FALSE; +} + +/************************************************************************** + * ReplaceFileA (KERNEL32.@) + */ +BOOL WINAPI ReplaceFileA(LPCSTR lpReplacedFileName,LPCSTR lpReplacementFileName, + LPCSTR lpBackupFileName, DWORD dwReplaceFlags, + LPVOID lpExclude, LPVOID lpReserved) +{ + FIXME("(%s,%s,%s,%08lx,%p,%p) stub\n",lpReplacedFileName,lpReplacementFileName, + lpBackupFileName,dwReplaceFlags,lpExclude,lpReserved); + SetLastError(ERROR_UNABLE_TO_MOVE_REPLACEMENT); + return FALSE; +}