Commit 8108a14b authored by Vitaly Lipatov's avatar Vitaly Lipatov

commit 14.0.3 upon wine-1.7.25

parent c926959a
......@@ -3021,6 +3021,22 @@ BOOL WINAPI ImmProcessKey(HWND hwnd, HKL hKL, UINT vKey, LPARAM lKeyData, DWORD
else
return FALSE;
/* Make sure we are inputting to the correct keyboard */
if (data->immKbd->hkl != hKL)
{
ImmHkl *new_hkl = IMM_GetImmHkl(hKL);
if (new_hkl)
{
data->immKbd->pImeSelect(imc, FALSE);
data->immKbd->uSelected--;
data->immKbd = new_hkl;
data->immKbd->pImeSelect(imc, TRUE);
data->immKbd->uSelected++;
}
else
return FALSE;
}
if (!data->immKbd->hIME || !data->immKbd->pImeProcessKey)
return FALSE;
......
......@@ -1638,6 +1638,20 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION **
#endif
/******************************************************************************
* CodeWeavers hack for bug 12412.
*/
#if defined(__APPLE__) && defined(__clang__)
#define NTQUERYSYSTEMINFORATION_FUNCNAME NtQuerySystemInformation_impl
__ASM_GLOBAL_FUNC( NtQuerySystemInformation,
"cmp %eax, %eax\n\t"
"je 1f\n\t"
"ret $0\n"
"1:\tjmp _NtQuerySystemInformation_impl" );
#else
#define NTQUERYSYSTEMINFORATION_FUNCNAME NtQuerySystemInformation
#endif /* End hack for bug 12412 */
/******************************************************************************
* NtQuerySystemInformation [NTDLL.@]
* ZwQuerySystemInformation [NTDLL.@]
*
......@@ -1656,7 +1670,7 @@ static NTSTATUS create_logical_proc_info(SYSTEM_LOGICAL_PROCESSOR_INFORMATION **
* Length size of the structure
* ResultLength Data written
*/
NTSTATUS WINAPI NtQuerySystemInformation(
NTSTATUS WINAPI NTQUERYSYSTEMINFORATION_FUNCNAME (
IN SYSTEM_INFORMATION_CLASS SystemInformationClass,
OUT PVOID SystemInformation,
IN ULONG Length,
......
......@@ -177,6 +177,8 @@
WINE_DEFAULT_DEBUG_CHANNEL(winsock);
WINE_DECLARE_DEBUG_CHANNEL(winediag);
static BOOL rift_hack;
/* names of the protocols */
static const WCHAR NameIpxW[] = {'I', 'P', 'X', '\0'};
static const WCHAR NameSpxW[] = {'S', 'P', 'X', '\0'};
......@@ -953,9 +955,21 @@ static void free_per_thread_data(void)
*/
BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID fImpLoad)
{
char buffer[MAX_PATH+1];
DWORD len;
TRACE("%p 0x%x %p\n", hInstDLL, fdwReason, fImpLoad);
switch (fdwReason) {
case DLL_PROCESS_ATTACH:
len = GetModuleFileNameA( 0, buffer, sizeof(buffer) );
if (len && len < MAX_PATH)
{
char *p, *appname = buffer;
if ((p = strrchr( appname, '/' ))) appname = p + 1;
if ((p = strrchr( appname, '\\' ))) appname = p + 1;
rift_hack = !strcasecmp(appname, "rift.exe");
}
break;
case DLL_PROCESS_DETACH:
if (fImpLoad) break;
......@@ -2006,7 +2020,10 @@ static NTSTATUS WS2_async_recv( void* user, IO_STATUS_BLOCK* iosb, NTSTATUS stat
{
iosb->u.Status = status;
iosb->Information = result;
*apc = ws2_async_apc;
if (wsa->completion_func || !rift_hack)
*apc = ws2_async_apc;
else
HeapFree(GetProcessHeap(), 0, wsa);
}
return status;
}
......
......@@ -975,7 +975,14 @@ static HANDLE start_rundll32( const char *inf_path, BOOL wow64 )
{
/* CROSSOVER HACK bug 7736. Do prefix initialization in the root desktop. */
static WCHAR root[] = {'r','o','o','t',0};
si.lpDesktop = root;
HDESK desktop;
desktop = CreateDesktopW(root, NULL, NULL, 0, GENERIC_ALL, NULL);
if (desktop)
{
SetThreadDesktop(desktop);
CloseHandle(desktop);
}
}
if (CreateProcessW( app, buffer, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi ))
......
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