From e3bf841067ab9a2bdc5c704c864024d564e47e7a Mon Sep 17 00:00:00 2001 From: Amine Khaldi Date: Sat, 23 Nov 2019 12:10:04 +0100 Subject: [PATCH] [QMGR] Sync with Wine Staging 4.18. CORE-16441 --- dll/win32/qmgr/file.c | 2 +- dll/win32/qmgr/job.c | 4 ++-- dll/win32/qmgr/qmgr.h | 13 ++++++------- media/doc/README.WINE | 2 +- 4 files changed, 10 insertions(+), 11 deletions(-) diff --git a/dll/win32/qmgr/file.c b/dll/win32/qmgr/file.c index dbdfc97bcc2..73b5992c087 100644 --- a/dll/win32/qmgr/file.c +++ b/dll/win32/qmgr/file.c @@ -459,7 +459,7 @@ static BOOL transfer_file_local(BackgroundCopyFileImpl *file, const WCHAR *tmpna transitionJobState(job, BG_JOB_STATE_QUEUED, BG_JOB_STATE_TRANSFERRING); - if (strlenW(file->info.RemoteName) > 7 && !memicmpW(file->info.RemoteName, fileW, 7)) + if (lstrlenW(file->info.RemoteName) > 7 && !_wcsnicmp(file->info.RemoteName, fileW, 7)) ptr = file->info.RemoteName + 7; else ptr = file->info.RemoteName; diff --git a/dll/win32/qmgr/job.c b/dll/win32/qmgr/job.c index a12e5111c52..0eef3361d46 100644 --- a/dll/win32/qmgr/job.c +++ b/dll/win32/qmgr/job.c @@ -599,7 +599,7 @@ static HRESULT WINAPI BackgroundCopyJob_SetDescription( if (!Val) return E_INVALIDARG; - len = strlenW(Val); + len = lstrlenW(Val); if (len > max_description_len) return BG_E_STRING_TOO_LONG; EnterCriticalSection(&This->cs); @@ -612,7 +612,7 @@ static HRESULT WINAPI BackgroundCopyJob_SetDescription( { HeapFree(GetProcessHeap(), 0, This->description); if ((This->description = HeapAlloc(GetProcessHeap(), 0, (len+1)*sizeof(WCHAR)))) - strcpyW(This->description, Val); + lstrcpyW(This->description, Val); else hr = E_OUTOFMEMORY; } diff --git a/dll/win32/qmgr/qmgr.h b/dll/win32/qmgr/qmgr.h index 2bc5b8b9615..87f8307a426 100644 --- a/dll/win32/qmgr/qmgr.h +++ b/dll/win32/qmgr/qmgr.h @@ -31,7 +31,6 @@ #include #include "wine/list.h" -#include "wine/unicode.h" /* Background copy job vtbl and related data */ typedef struct @@ -118,15 +117,15 @@ BOOL transitionJobState(BackgroundCopyJobImpl *job, BG_JOB_STATE from, BG_JOB_ST /* Little helper functions */ static inline WCHAR *strdupW(const WCHAR *src) { - WCHAR *dst = HeapAlloc(GetProcessHeap(), 0, (strlenW(src) + 1) * sizeof(WCHAR)); - if (dst) strcpyW(dst, src); + WCHAR *dst = HeapAlloc(GetProcessHeap(), 0, (lstrlenW(src) + 1) * sizeof(WCHAR)); + if (dst) lstrcpyW(dst, src); return dst; } static inline WCHAR *co_strdupW(const WCHAR *src) { - WCHAR *dst = CoTaskMemAlloc((strlenW(src) + 1) * sizeof(WCHAR)); - if (dst) strcpyW(dst, src); + WCHAR *dst = CoTaskMemAlloc((lstrlenW(src) + 1) * sizeof(WCHAR)); + if (dst) lstrcpyW(dst, src); return dst; } @@ -136,10 +135,10 @@ static inline HRESULT return_strval(const WCHAR *str, WCHAR **ret) if (!ret) return E_INVALIDARG; - len = strlenW(str); + len = lstrlenW(str); *ret = CoTaskMemAlloc((len+1)*sizeof(WCHAR)); if (!*ret) return E_OUTOFMEMORY; - strcpyW(*ret, str); + lstrcpyW(*ret, str); return S_OK; } diff --git a/media/doc/README.WINE b/media/doc/README.WINE index 2ac9a1e0072..3835269c8a9 100644 --- a/media/doc/README.WINE +++ b/media/doc/README.WINE @@ -154,7 +154,7 @@ dll/win32/powrprof # Forked at Wine-1.0rc5 dll/win32/printui # Synced to WineStaging-4.18 dll/win32/propsys # Synced to WineStaging-4.18 dll/win32/pstorec # Synced to WineStaging-3.3 -dll/win32/qmgr # Synced to WineStaging-4.0 +dll/win32/qmgr # Synced to WineStaging-4.18 dll/win32/qmgrprxy # Synced to WineStaging-2.9 dll/win32/query # Synced to WineStaging-3.3 dll/win32/rasapi32 # Synced to WineStaging-3.3