BOOL b = ::SymLoadModule(myProcess, NULL, (char*)aLibraryName, (char*)aLibraryName, 0, 0);
if (!ok) { LPVOID lpMsgBuf; FormatMessage( FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS, NULL, GetLastError(), MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), (LPTSTR) &lpMsgBuf, 0, NULL ); fprintf(stdout, "### ERROR: LoadLibrarySymbols for %s: %s\n", aLibraryName, lpMsgBuf); fflush(stdout); LocalFree( lpMsgBuf ); }
nsTraceRefcnt::LoadLibrarySymbols(const char* aLibraryName,                                  void* aLibrayHandle){#ifdef MOZ_TRACE_XPCOM_REFCNT#if defined(_WIN32) && defined(_M_IX86) /* Win32 x86 only */  InitTraceLog();  if (PR_LOG_TEST(gTraceRefcntLog,PR_LOG_DEBUG)) {    HANDLE myProcess = ::GetCurrentProcess();    if (!SymInitialize(myProcess, ".;..\\lib", TRUE)) {      return;    }    BOOL b = ::SymLoadModule(myProcess,                             NULL,                             (char*)aLibraryName,                             (char*)aLibraryName,                             0,                             0);//  DWORD lastError = 0;//  if (!b) lastError = ::GetLastError();//  printf("loading symbols for library %s => %s [%d]\n", aLibraryName,//         b ? "true" : "false", lastError);  }#endif#endif}