library of assembled shared sources |
http://lass.cocamware.com |
Public Types | |
enum | { bufferSize_ = _MAX_PATH, numPatchBytes_ = 5 } |
typedef CrashDump::TCallback | TCallback |
typedef util::CriticalSection | TMutex |
typedef void(* | TCallback )(const char *, void *) |
typedef BOOL(WINAPI * | TMiniDumpWriteDump )(HANDLE hProcess, DWORD ProcessId, HANDLE hFile, MINIDUMP_TYPE DumpType, CONST PMINIDUMP_EXCEPTION_INFORMATION ExceptionParam, CONST PMINIDUMP_USER_STREAM_INFORMATION UserStreamParam, CONST PMINIDUMP_CALLBACK_INFORMATION CallbackParam) |
Public Member Functions | |
CrashDumpImpl (const std::string &name, TCallback callback, void *callbackClosure) | |
void | init () |
~CrashDumpImpl () | |
CrashDumpImpl (const std::string &name, TCallback callback, void *callbackClosure) | |
void | init () |
~CrashDumpImpl () | |
const HMODULE | loadLibrary (const TCHAR *libraryName) const |
const HMODULE | loadSideLibrary (const TCHAR *libraryName, HMODULE me) const |
void | patchSetUnhandledExceptionFilter (bool patch) |
void | handlerThread () |
void | doHandleException () |
Static Public Member Functions | |
static void | writeMemory (void *dest, const void *source, size_t size) |
static LONG WINAPI | unhandledExceptionFilter (struct _EXCEPTION_POINTERS *exceptionInfo) |
Data Fields | |
std::vector< char > | dumpFilename_ |
std::vector< TCHAR > | dumpFilenameT_ |
TCallback | callback_ |
void * | callbackClosure_ |
HMODULE | dbghelp_ |
TMiniDumpWriteDump | miniDumpWriteDump_ |
util::ScopedPtr< Thread > | handlerThread_ |
util::Condition | handleCondition_ |
util::Condition | resultCondition_ |
TMutex * | mutex_ |
LPTOP_LEVEL_EXCEPTION_FILTER | oldFilter_ |
char | oldBytes_ [numPatchBytes_] |
_EXCEPTION_POINTERS * | exceptionInfo_ |
DWORD | threadId_ |
LONG | handlerResult_ |
volatile bool | isExiting_ |
volatile bool | isHandlingException_ |
Static Public Attributes | |
static CrashDumpImpl * | instance_ = 0 |
static char | patchBytes_ [numPatchBytes_] = { 0x33, 0xc0, 0xc2, 0x04, 0x00 } |
Definition at line 56 of file crash_dump.cpp.
Definition at line 59 of file crash_dump.cpp.
Definition at line 204 of file crash_dump_win32.inl.
typedef void(* lass::util::impl::CrashDumpImpl::TCallback)(const char *, void *) |
typedef BOOL(WINAPI * lass::util::impl::CrashDumpImpl::TMiniDumpWriteDump)(HANDLE hProcess, DWORD ProcessId, HANDLE hFile, MINIDUMP_TYPE DumpType, CONST PMINIDUMP_EXCEPTION_INFORMATION ExceptionParam, CONST PMINIDUMP_USER_STREAM_INFORMATION UserStreamParam, CONST PMINIDUMP_CALLBACK_INFORMATION CallbackParam) |
anonymous enum |
lass::util::impl::CrashDumpImpl::CrashDumpImpl | ( | const std::string & | name, | |
TCallback | callback, | |||
void * | callbackClosure | |||
) | [inline] |
Definition at line 60 of file crash_dump.cpp.
lass::util::impl::CrashDumpImpl::~CrashDumpImpl | ( | ) | [inline] |
Definition at line 62 of file crash_dump.cpp.
lass::util::impl::CrashDumpImpl::CrashDumpImpl | ( | const std::string & | name, | |
TCallback | callback, | |||
void * | callbackClosure | |||
) | [inline] |
Definition at line 104 of file crash_dump_win32.inl.
References dumpFilename_, dumpFilenameT_, instance_, LASS_ENFORCE_COM, and LASS_THROW.
lass::util::impl::CrashDumpImpl::~CrashDumpImpl | ( | ) | [inline] |
Definition at line 175 of file crash_dump_win32.inl.
References dbghelp_, handleCondition_, handlerThread_, instance_, isExiting_, LASS_EXPERIMENTAL_CATCH_AND_REPORT, mutex_, oldFilter_, patchSetUnhandledExceptionFilter(), and lass::util::Condition::signal().
void lass::util::impl::CrashDumpImpl::init | ( | ) | [inline] |
void lass::util::impl::CrashDumpImpl::init | ( | ) | [inline] |
Definition at line 153 of file crash_dump_win32.inl.
References dbghelp_, handlerThread(), handlerThread_, instance_, isExiting_, LASS_THROW, loadLibrary(), miniDumpWriteDump_, mutex_, oldFilter_, patchSetUnhandledExceptionFilter(), lass::util::threadJoinable, lass::util::threadMemFun(), and unhandledExceptionFilter().
const HMODULE lass::util::impl::CrashDumpImpl::loadLibrary | ( | const TCHAR * | libraryName | ) | const [inline] |
Definition at line 206 of file crash_dump_win32.inl.
References lass::dll::getLassInstance(), LASS_THROW, and loadSideLibrary().
Referenced by init().
const HMODULE lass::util::impl::CrashDumpImpl::loadSideLibrary | ( | const TCHAR * | libraryName, | |
HMODULE | me | |||
) | const [inline] |
Definition at line 235 of file crash_dump_win32.inl.
References bufferSize_.
Referenced by loadLibrary().
void lass::util::impl::CrashDumpImpl::patchSetUnhandledExceptionFilter | ( | bool | patch | ) | [inline] |
Definition at line 265 of file crash_dump_win32.inl.
References LASS_ENFORCE, numPatchBytes_, oldBytes_, patchBytes_, and writeMemory().
Referenced by init(), and ~CrashDumpImpl().
static void lass::util::impl::CrashDumpImpl::writeMemory | ( | void * | dest, | |
const void * | source, | |||
size_t | size | |||
) | [inline, static] |
Definition at line 281 of file crash_dump_win32.inl.
Referenced by patchSetUnhandledExceptionFilter().
void lass::util::impl::CrashDumpImpl::handlerThread | ( | ) | [inline] |
Definition at line 289 of file crash_dump_win32.inl.
References callback_, callbackClosure_, lass::io::cerr(), doHandleException(), dumpFilename_, handleCondition_, isExiting_, isHandlingException_, resultCondition_, lass::util::Condition::signal(), and lass::util::Condition::wait().
Referenced by init().
void lass::util::impl::CrashDumpImpl::doHandleException | ( | ) | [inline] |
Definition at line 319 of file crash_dump_win32.inl.
References dumpFilenameT_, exceptionInfo_, handlerResult_, miniDumpWriteDump_, and threadId_.
Referenced by handlerThread().
static LONG WINAPI lass::util::impl::CrashDumpImpl::unhandledExceptionFilter | ( | struct _EXCEPTION_POINTERS * | exceptionInfo | ) | [inline, static] |
Definition at line 344 of file crash_dump_win32.inl.
References exceptionInfo_, handleCondition_, handlerResult_, instance_, isHandlingException_, LASS_LOCK, mutex_, resultCondition_, lass::util::Condition::signal(), threadId_, and lass::util::Condition::wait().
Referenced by init().
std::vector<char> lass::util::impl::CrashDumpImpl::dumpFilename_ |
Definition at line 366 of file crash_dump_win32.inl.
Referenced by CrashDumpImpl(), and handlerThread().
std::vector<TCHAR> lass::util::impl::CrashDumpImpl::dumpFilenameT_ |
Definition at line 367 of file crash_dump_win32.inl.
Referenced by CrashDumpImpl(), and doHandleException().
Definition at line 373 of file crash_dump_win32.inl.
Referenced by handlerThread(), unhandledExceptionFilter(), and ~CrashDumpImpl().
Definition at line 374 of file crash_dump_win32.inl.
Referenced by handlerThread(), and unhandledExceptionFilter().
Definition at line 375 of file crash_dump_win32.inl.
Referenced by init(), unhandledExceptionFilter(), and ~CrashDumpImpl().
LPTOP_LEVEL_EXCEPTION_FILTER lass::util::impl::CrashDumpImpl::oldFilter_ |
char lass::util::impl::CrashDumpImpl::oldBytes_[numPatchBytes_] |
Definition at line 377 of file crash_dump_win32.inl.
Referenced by patchSetUnhandledExceptionFilter().
_EXCEPTION_POINTERS* lass::util::impl::CrashDumpImpl::exceptionInfo_ |
Definition at line 379 of file crash_dump_win32.inl.
Referenced by doHandleException(), and unhandledExceptionFilter().
Definition at line 380 of file crash_dump_win32.inl.
Referenced by doHandleException(), and unhandledExceptionFilter().
Definition at line 381 of file crash_dump_win32.inl.
Referenced by doHandleException(), and unhandledExceptionFilter().
volatile bool lass::util::impl::CrashDumpImpl::isExiting_ |
Definition at line 383 of file crash_dump_win32.inl.
Referenced by handlerThread(), init(), and ~CrashDumpImpl().
volatile bool lass::util::impl::CrashDumpImpl::isHandlingException_ |
Definition at line 384 of file crash_dump_win32.inl.
Referenced by handlerThread(), and unhandledExceptionFilter().
CrashDumpImpl * lass::util::impl::CrashDumpImpl::instance_ = 0 [static] |
Definition at line 386 of file crash_dump_win32.inl.
Referenced by CrashDumpImpl(), init(), unhandledExceptionFilter(), and ~CrashDumpImpl().
char lass::util::impl::CrashDumpImpl::patchBytes_ = { 0x33, 0xc0, 0xc2, 0x04, 0x00 } [static] |
Definition at line 387 of file crash_dump_win32.inl.
Referenced by patchSetUnhandledExceptionFilter().
Generated on Mon Nov 10 14:22:18 2008 for Library of Assembled Shared Sources by 1.5.7.1 |