mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-28 12:51:03 +00:00
[Refs #87: Static Analysis] Handle NULL parameters separately
This commit is contained in:
@@ -310,7 +310,10 @@ static bool OrdinalAsString(void *func)
|
||||
|
||||
FARPROC WINAPI Hooked_GetProcAddress(HMODULE mod, LPCSTR func)
|
||||
{
|
||||
if(mod == s_HookData->module || mod == NULL || func == NULL || OrdinalAsString((void *)func))
|
||||
if(mod == NULL || func == NULL)
|
||||
return (FARPROC)NULL;
|
||||
|
||||
if(mod == s_HookData->module || OrdinalAsString((void *)func))
|
||||
return GetProcAddress(mod, func);
|
||||
|
||||
for(auto it=s_HookData->DllHooks.begin(); it != s_HookData->DllHooks.end(); ++it)
|
||||
|
||||
Reference in New Issue
Block a user