From 6e3a173c7f49f744d14e9bc4062ec12e4fd0f395 Mon Sep 17 00:00:00 2001 From: baldurk Date: Wed, 23 May 2018 16:00:42 +0100 Subject: [PATCH] Fetch ordinal names if we emergency-fetch module in GetProcAddress --- renderdoc/os/win32/win32_hook.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/renderdoc/os/win32/win32_hook.cpp b/renderdoc/os/win32/win32_hook.cpp index 5337627e4..dd6a707d1 100644 --- a/renderdoc/os/win32/win32_hook.cpp +++ b/renderdoc/os/win32/win32_hook.cpp @@ -663,7 +663,11 @@ FARPROC WINAPI Hooked_GetProcAddress(HMODULE mod, LPCSTR func) for(auto it = s_HookData->DllHooks.begin(); it != s_HookData->DllHooks.end(); ++it) { if(it->second.module == NULL) + { it->second.module = GetModuleHandleA(it->first.c_str()); + if(it->second.module) + it->second.FetchOrdinalNames(); + } bool match = (mod == it->second.module);