Go to the documentation of this file.
93 , m_stack(
"************ Dump Begin ************\n")
97 m_stack +=
"************* Dump End *************";
113 #define GOTODEBDEF true
115 #define GOTODEBDEF false
130 LONG journallerExceptionFilter(EXCEPTION_POINTERS* pExPtrs,
Journaller* journal)
132 journal->
log(
JLL_Fatal,
"******* C level exception (CRASH) *******");
133 journal->
log(
JLL_Fatal,
"************ Dump Begin ************");
135 sw.
ShowCallstack(GetCurrentThread(), pExPtrs->ContextRecord);
136 journal->
log(
JLL_Fatal,
"************* Dump End *************");
BOOL ShowCallstack(HANDLE hThread=GetCurrentThread(), const CONTEXT *context=NULL, PReadProcessMemoryRoutine readMemoryFunction=NULL, LPVOID pUserData=NULL)
A helper class that combines the StackWalker output into a std::string.
JournalException(std::string const &message)
Constructor, copies the message and creates a stack dump.
JournalExceptionStackWalker(JournalException *exc)
@ XRV_ERROR
256: A generic error occurred
A journalling class for debugging applications.
@ JLL_Fatal
only log fatal messages
An exception class that automatically includes stack dump information.
const std::string & stack() const
The stack dump as it was at the time of object construction.
const char * msg() const
The message as supplied to the constructor.
std::string m_stack
A string that contains a stack dump.
void log(JournalLogLevel level, const std::string &msg)
Write a log message to the file if level is at least equal to the current log level.
bool gOnExceptionGotoDebugger
A class that can help with walking the stack for debugging purposes (Windows version)
JournalException * m_exception
virtual void OnOutput(LPCSTR szText)
const typedef std::string & LPCSTR
A journaller class that is used for walking the stack.