From 774ee4734a7d6c02f648fdf1747df837c964583d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Bernon?= Date: Fri, 31 Jul 2020 14:22:34 +0200 Subject: [PATCH] dbghelp: Ignore missing debug info in SymInitializeW. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When fInvadeProcess is used, we return an error if the target process is found but its debug info is not. We should only return an error if the process is not found. This fixes a SymInitializeW popup error on Hard Reset Redux startup. Signed-off-by: RĂ©mi Bernon Signed-off-by: Alexandre Julliard --- dlls/dbghelp/dbghelp.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/dlls/dbghelp/dbghelp.c b/dlls/dbghelp/dbghelp.c index a2dba4cfe3e..9d33bc67f2b 100644 --- a/dlls/dbghelp/dbghelp.c +++ b/dlls/dbghelp/dbghelp.c @@ -354,7 +354,9 @@ static BOOL check_live_target(struct process* pcs) if (!base) return FALSE; TRACE("got debug info address %#lx from PEB %p\n", base, pbi.PebBaseAddress); - return elf_read_wine_loader_dbg_info(pcs, base) || macho_read_wine_loader_dbg_info(pcs, base); + if (!elf_read_wine_loader_dbg_info(pcs, base) && !macho_read_wine_loader_dbg_info(pcs, base)) + WARN("couldn't load process debug info at %#lx\n", base); + return TRUE; } /****************************************************************** @@ -456,7 +458,7 @@ BOOL WINAPI SymInitializeW(HANDLE hProcess, PCWSTR UserSearchPath, BOOL fInvadeP { if (fInvadeProcess) EnumerateLoadedModulesW64(hProcess, process_invade_cb, hProcess); - pcs->loader->synchronize_module_list(pcs); + if (pcs->loader) pcs->loader->synchronize_module_list(pcs); } else if (fInvadeProcess) {