Commit b5346a8c authored by Alexandre Julliard's avatar Alexandre Julliard

user32: Fix the DDE service formatting for 64-bit.

parent 7bac0f52
......@@ -1647,7 +1647,7 @@ HGLOBAL WDML_DataHandle2Global(HDDEDATA hDdeData, BOOL fResponse, BOOL fRelease,
*/
WDML_SERVER* WDML_AddServer(WDML_INSTANCE* pInstance, HSZ hszService, HSZ hszTopic)
{
static const WCHAR fmtW[] = {'%','s','(','0','x','%','0','8','l','x',')',0};
static const WCHAR fmtW[] = {'%','s','(','0','x','%','*','x',')',0};
WDML_SERVER* pServer;
WCHAR buf1[256];
WCHAR buf2[256];
......@@ -1659,7 +1659,7 @@ WDML_SERVER* WDML_AddServer(WDML_INSTANCE* pInstance, HSZ hszService, HSZ hszTop
WDML_IncHSZ(pInstance, hszService);
DdeQueryStringW(pInstance->instanceID, hszService, buf1, 256, CP_WINUNICODE);
snprintfW(buf2, 256, fmtW, buf1, GetCurrentProcessId());
snprintfW(buf2, 256, fmtW, buf1, 2*sizeof(ULONG_PTR), GetCurrentProcessId());
pServer->hszServiceSpec = DdeCreateStringHandleW(pInstance->instanceID, buf2, CP_WINUNICODE);
pServer->atomService = WDML_MakeAtomFromHsz(pServer->hszService);
......
......@@ -585,7 +585,7 @@ static HDDEDATA CALLBACK server_ddeml_callback(UINT uType, UINT uFmt, HCONV hcon
size = DdeQueryStringA(server_pid, hsz2, str, MAX_PATH, CP_WINANSI);
ok(!strncmp(str, "TestDDEServer(", 14), "Expected TestDDEServer(, got %s\n", str);
ok(str[size - 1] == ')', "Expected ')', got %c\n", str[size - 1]);
ok(size == 25, "Expected 25, got %d\n", size);
ok(size == 17 + 2*sizeof(ULONG_PTR), "Got size %d for %s\n", size, str);
return (HDDEDATA)TRUE;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment