From 165434a1f016184c77c27b9d64fa08669fe0de6d Mon Sep 17 00:00:00 2001 From: baldurk Date: Fri, 22 Jun 2018 16:06:33 +0100 Subject: [PATCH] For completely unknown GL functions, return the original function * CheckUnsupported handles all known compatibility GL functions and extension functions, so this would only be true for an unpublished or completely new extension. It might break, but if it's an internal function call it's better to pass it through. --- renderdoc/driver/gl/gl_hooks_linux_shared.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/renderdoc/driver/gl/gl_hooks_linux_shared.cpp b/renderdoc/driver/gl/gl_hooks_linux_shared.cpp index 89960c73c..bb4e19262 100644 --- a/renderdoc/driver/gl/gl_hooks_linux_shared.cpp +++ b/renderdoc/driver/gl/gl_hooks_linux_shared.cpp @@ -1417,8 +1417,10 @@ void *SharedLookupFuncPtr(const char *func, void *realFunc) CheckUnsupported(); // for any other function, if it's not a core or extension function we know about, - // just return NULL - return NULL; + // return the real function pointer as this may be something internal + RDCLOG("Returning real pointer for entirely unknown function '%s': %p", func, realFunc); + + return realFunc; } bool SharedPopulateHooks(bool dlsymFirst, void *(*lookupFunc)(const char *))