mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-10-25 08:08:50 +00:00
[Refs #87: Static Analysis] Handle NULL parameters separately
This commit is contained in:
1 parent
efbc27909c
commit
20e86183bf
1 file changed
+4
-1
@@ -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