[Bf-blender-cvs] [a1c2441390e] master: Windows: Improve private symbol detection

Ray Molenkamp noreply at git.blender.org
Fri May 8 17:46:46 CEST 2020


Commit: a1c2441390e6b56da53dd914a6d6a81de84dc46c
Author: Ray Molenkamp
Date:   Fri May 8 09:46:39 2020 -0600
Branches: master
https://developer.blender.org/rBa1c2441390e6b56da53dd914a6d6a81de84dc46c

Windows: Improve private symbol detection

To detect if private of public symbols were loaded we were relying
on a strcmp with a known filename, which was not great, the symbol
api has a field we can query which should be more flexible and
reliable.

===================================================================

M	source/blender/blenlib/intern/system_win32.c

===================================================================

diff --git a/source/blender/blenlib/intern/system_win32.c b/source/blender/blenlib/intern/system_win32.c
index 115432bc7d5..5a633755c79 100644
--- a/source/blender/blenlib/intern/system_win32.c
+++ b/source/blender/blenlib/intern/system_win32.c
@@ -309,8 +309,7 @@ static bool bli_private_symbols_loaded()
   IMAGEHLP_MODULE64 m64;
   m64.SizeOfStruct = sizeof(m64);
   if (SymGetModuleInfo64(GetCurrentProcess(), (DWORD64)GetModuleHandle(NULL), &m64)) {
-    PathStripPath(m64.LoadedPdbName);
-    return BLI_strcasecmp(m64.LoadedPdbName, "blender_private.pdb") == 0;
+    return m64.GlobalSymbols;
   }
   return false;
 }



More information about the Bf-blender-cvs mailing list