[MAPI32] Sync with Wine Staging 4.18. CORE-16441

This commit is contained in:
Amine Khaldi 2019-11-09 21:50:53 +01:00
parent de78eb16d7
commit 9d3a9694f4
5 changed files with 15 additions and 21 deletions

View file

@ -2,8 +2,6 @@
#ifndef _MAPI32_PCH_
#define _MAPI32_PCH_
#include <wine/config.h>
#include <stdarg.h>
#define WIN32_NO_STATUS
@ -17,12 +15,12 @@
#include <windef.h>
#include <winbase.h>
#include <winreg.h>
#include <winnls.h>
#include <mapi.h>
#include <mapival.h>
#include <shlwapi.h>
#include <wine/debug.h>
#include <wine/unicode.h>
#include "util.h"

View file

@ -29,7 +29,6 @@
#include "shlwapi.h"
#include "wine/list.h"
#include "wine/debug.h"
#include "wine/unicode.h"
#include "mapival.h"
WINE_DEFAULT_DEBUG_CHANNEL(mapi);
@ -91,7 +90,7 @@ SCODE WINAPI PropCopyMore(LPSPropValue lpDest, LPSPropValue lpSrc,
memcpy(lpDest->Value.lpszA, lpSrc->Value.lpszA, ulLen);
break;
case PT_UNICODE:
ulLen = (strlenW(lpSrc->Value.lpszW) + 1u) * sizeof(WCHAR);
ulLen = (lstrlenW(lpSrc->Value.lpszW) + 1u) * sizeof(WCHAR);
scode = lpMore(ulLen, lpOrig, (LPVOID*)&lpDest->Value.lpszW);
if (SUCCEEDED(scode))
memcpy(lpDest->Value.lpszW, lpSrc->Value.lpszW, ulLen);
@ -156,7 +155,7 @@ SCODE WINAPI PropCopyMore(LPSPropValue lpDest, LPSPropValue lpSrc,
for (i = 0; i < lpSrc->Value.MVszW.cValues; i++)
{
ULONG ulStrLen = strlenW(lpSrc->Value.MVszW.lppszW[i]) + 1u;
ULONG ulStrLen = lstrlenW(lpSrc->Value.MVszW.lppszW[i]) + 1u;
lpDest->Value.MVszW.lppszW[i] = lpNextStr;
memcpy(lpNextStr, lpSrc->Value.MVszW.lppszW[i], ulStrLen * sizeof(WCHAR));
@ -263,7 +262,7 @@ ULONG WINAPI UlPropSize(LPSPropValue lpProp)
break;
case PT_MV_UNICODE: ulRet = 0u;
for (i = 0; i < lpProp->Value.MVszW.cValues; i++)
ulRet += (strlenW(lpProp->Value.MVszW.lppszW[i]) + 1u);
ulRet += (lstrlenW(lpProp->Value.MVszW.lppszW[i]) + 1u);
ulRet *= sizeof(WCHAR);
break;
case PT_UNICODE: ulRet = (lstrlenW(lpProp->Value.lpszW) + 1u) * sizeof(WCHAR);
@ -504,7 +503,7 @@ LONG WINAPI LPropCompareProp(LPSPropValue lpPropLeft, LPSPropValue lpPropRight)
case PT_STRING8:
return lstrcmpA(lpPropLeft->Value.lpszA, lpPropRight->Value.lpszA);
case PT_UNICODE:
return strcmpW(lpPropLeft->Value.lpszW, lpPropRight->Value.lpszW);
return lstrcmpW(lpPropLeft->Value.lpszW, lpPropRight->Value.lpszW);
case PT_ERROR:
if (lpPropLeft->Value.err > lpPropRight->Value.err)
return 1;
@ -828,7 +827,7 @@ SCODE WINAPI ScCopyProps(int cValues, LPSPropValue lpProps, LPVOID lpDst, ULONG
lpDataDest += ulLen;
break;
case PT_UNICODE:
ulLen = (strlenW(lpProps->Value.lpszW) + 1u) * sizeof(WCHAR);
ulLen = (lstrlenW(lpProps->Value.lpszW) + 1u) * sizeof(WCHAR);
lpDest->Value.lpszW = (LPWSTR)lpDataDest;
memcpy(lpDest->Value.lpszW, lpProps->Value.lpszW, ulLen);
lpDataDest += ulLen;
@ -867,7 +866,7 @@ SCODE WINAPI ScCopyProps(int cValues, LPSPropValue lpProps, LPVOID lpDst, ULONG
for (i = 0; i < lpProps->Value.MVszW.cValues; i++)
{
ULONG ulStrLen = (strlenW(lpProps->Value.MVszW.lppszW[i]) + 1u) * sizeof(WCHAR);
ULONG ulStrLen = (lstrlenW(lpProps->Value.MVszW.lppszW[i]) + 1u) * sizeof(WCHAR);
lpDest->Value.MVszW.lppszW[i] = (LPWSTR)lpDataDest;
memcpy(lpDataDest, lpProps->Value.MVszW.lppszW[i], ulStrLen);
@ -981,7 +980,7 @@ SCODE WINAPI ScRelocProps(int cValues, LPSPropValue lpProps, LPVOID lpOld,
ulLen = bBadPtr ? 0 : (lstrlenW(lpDest->Value.lpszW) + 1u) * sizeof(WCHAR);
lpDest->Value.lpszW = (LPWSTR)RELOC_PTR(lpDest->Value.lpszW);
if (bBadPtr)
ulLen = (strlenW(lpDest->Value.lpszW) + 1u) * sizeof(WCHAR);
ulLen = (lstrlenW(lpDest->Value.lpszW) + 1u) * sizeof(WCHAR);
ulCount += ulLen;
break;
case PT_BINARY:
@ -1020,11 +1019,11 @@ SCODE WINAPI ScRelocProps(int cValues, LPSPropValue lpProps, LPVOID lpOld,
for (i = 0; i < lpDest->Value.MVszW.cValues; i++)
{
ULONG ulStrLen = bBadPtr ? 0 : (strlenW(lpDest->Value.MVszW.lppszW[i]) + 1u) * sizeof(WCHAR);
ULONG ulStrLen = bBadPtr ? 0 : (lstrlenW(lpDest->Value.MVszW.lppszW[i]) + 1u) * sizeof(WCHAR);
lpDest->Value.MVszW.lppszW[i] = (LPWSTR)RELOC_PTR(lpDest->Value.MVszW.lppszW[i]);
if (bBadPtr)
ulStrLen = (strlenW(lpDest->Value.MVszW.lppszW[i]) + 1u) * sizeof(WCHAR);
ulStrLen = (lstrlenW(lpDest->Value.MVszW.lppszW[i]) + 1u) * sizeof(WCHAR);
ulCount += ulStrLen;
}
break;

View file

@ -19,8 +19,6 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "config.h"
#include "wine/port.h"
#include <stdio.h>
#include <stdarg.h>

View file

@ -33,7 +33,6 @@
#include "objbase.h"
#include "shlwapi.h"
#include "wine/debug.h"
#include "wine/unicode.h"
#include "mapival.h"
#include "xcmc.h"
#include "msi.h"
@ -404,7 +403,7 @@ VOID WINAPI SwapPword(PUSHORT lpData, ULONG ulLen)
ULONG WINAPI MNLS_lstrlenW(LPCWSTR lpszStr)
{
TRACE("(%s)\n", debugstr_w(lpszStr));
return strlenW(lpszStr);
return lstrlenW(lpszStr);
}
/*************************************************************************
@ -423,7 +422,7 @@ ULONG WINAPI MNLS_lstrlenW(LPCWSTR lpszStr)
INT WINAPI MNLS_lstrcmpW(LPCWSTR lpszLeft, LPCWSTR lpszRight)
{
TRACE("(%s,%s)\n", debugstr_w(lpszLeft), debugstr_w(lpszRight));
return strcmpW(lpszLeft, lpszRight);
return lstrcmpW(lpszLeft, lpszRight);
}
/*************************************************************************
@ -443,7 +442,7 @@ ULONG WINAPI MNLS_lstrcpyW(LPWSTR lpszDest, LPCWSTR lpszSrc)
ULONG len;
TRACE("(%p,%s)\n", lpszDest, debugstr_w(lpszSrc));
len = (strlenW(lpszSrc) + 1) * sizeof(WCHAR);
len = (lstrlenW(lpszSrc) + 1) * sizeof(WCHAR);
memcpy(lpszDest, lpszSrc, len);
return len;
}
@ -494,7 +493,7 @@ BOOL WINAPI FEqualNames(LPMAPINAMEID lpName1, LPMAPINAMEID lpName2)
return FALSE;
if (lpName1->ulKind == MNID_STRING)
return !strcmpW(lpName1->Kind.lpwstrName, lpName2->Kind.lpwstrName);
return !lstrcmpW(lpName1->Kind.lpwstrName, lpName2->Kind.lpwstrName);
return lpName1->Kind.lID == lpName2->Kind.lID;
}

View file

@ -90,7 +90,7 @@ dll/win32/jscript # Synced to WineStaging-4.18
dll/win32/jsproxy # Synced to WineStaging-4.18
dll/win32/loadperf # Synced to WineStaging-4.18
dll/win32/lz32 # Synced to WineStaging-3.3
dll/win32/mapi32 # Synced to WineStaging-4.0
dll/win32/mapi32 # Synced to WineStaging-4.18
dll/win32/mciavi32 # Synced to WineStaging-3.3
dll/win32/mcicda # Synced to WineStaging-3.3
dll/win32/mciqtz32 # Synced to WineStaging-3.3