MCPcopy Create free account
hub / github.com/bwapi/bwapi / getModuleNameFrom

Function getModuleNameFrom

bwapi/BWAPI/Source/ExceptionFilter.cpp:39–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

37};
38
39std::string getModuleNameFrom(LPCVOID pExcptAddr)
40{
41 MEMORY_BASIC_INFORMATION memInfo;
42 char szOffender[MAX_PATH] = { "_unknown_" };
43 if ( VirtualQuery(pExcptAddr, &memInfo, sizeof(memInfo)) )
44 GetModuleFileNameA(memInfo.AllocationBase ? (HMODULE)memInfo.AllocationBase : GetModuleHandle(NULL), szOffender, MAX_PATH);
45 char *pszLast = strrchr(szOffender, '\\');
46 return std::string(pszLast ? pszLast + 1 : szOffender);
47}
48
49void GetCurrentProductVersion(WORD &w1, WORD &w2, WORD &w3, WORD &w4)
50{

Callers 1

BWAPIExceptionFilterFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected