MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / FormatException

Function FormatException

src/util/exception.cpp:20–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18#endif // WIN32
19
20static std::string FormatException(const std::exception* pex, std::string_view thread_name)
21{
22#ifdef WIN32
23 char pszModule[MAX_PATH] = "";
24 GetModuleFileNameA(nullptr, pszModule, sizeof(pszModule));
25#else
26 const char* pszModule = "bitcoin";
27#endif
28 if (pex)
29 return strprintf(
30 "EXCEPTION: %s \n%s \n%s in %s \n", typeid(*pex).name(), pex->what(), pszModule, thread_name);
31 else
32 return strprintf(
33 "UNKNOWN EXCEPTION \n%s in %s \n", pszModule, thread_name);
34}
35
36void PrintExceptionContinue(const std::exception* pex, std::string_view thread_name)
37{

Callers 1

PrintExceptionContinueFunction · 0.85

Calls 1

whatMethod · 0.45

Tested by

no test coverage detected