Commit 31ffa547 authored by Hans Leidekker's avatar Hans Leidekker Committed by Alexandre Julliard

kernel32: GetModuleHandleEx already clears the module handle on failure.

parent f96c7278
......@@ -570,7 +570,7 @@ HMODULE WINAPI DECLSPEC_HOTPATCH GetModuleHandleA(LPCSTR module)
{
HMODULE ret;
if (!GetModuleHandleExA( GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT, module, &ret )) ret = 0;
GetModuleHandleExA( GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT, module, &ret );
return ret;
}
......@@ -583,7 +583,7 @@ HMODULE WINAPI GetModuleHandleW(LPCWSTR module)
{
HMODULE ret;
if (!GetModuleHandleExW( GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT, module, &ret )) ret = 0;
GetModuleHandleExW( GET_MODULE_HANDLE_EX_FLAG_UNCHANGED_REFCOUNT, module, &ret );
return ret;
}
......
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