Commit f2f27b6b authored by Eric Pouech's avatar Eric Pouech Committed by Alexandre Julliard

dbghelp: SymLoadModule* should return the base address in case of success, and 0 otherwise.

parent 3f95a56e
......@@ -786,19 +786,19 @@ DWORD64 WINAPI SymLoadModuleExW(HANDLE hProcess, HANDLE hFile, PCWSTR wImageNam
if (Data)
FIXME("Unsupported load data parameter %p for %s\n",
Data, debugstr_w(wImageName));
if (!validate_addr64(BaseOfDll)) return FALSE;
if (!validate_addr64(BaseOfDll)) return 0;
if (!(pcs = process_find_by_handle(hProcess))) return FALSE;
if (!(pcs = process_find_by_handle(hProcess))) return 0;
if (Flags & SLMFLAG_VIRTUAL)
{
if (!wImageName) return FALSE;
if (!wImageName) return 0;
module = module_new(pcs, wImageName, DMT_PE, TRUE, BaseOfDll, SizeOfDll, 0, 0);
if (!module) return FALSE;
if (!module) return 0;
if (wModuleName) module_set_module(module, wModuleName);
module->module.SymType = SymVirtual;
return TRUE;
return module->module.BaseOfImage;
}
if (Flags & ~(SLMFLAG_VIRTUAL))
FIXME("Unsupported Flags %08x for %s\n", Flags, debugstr_w(wImageName));
......
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