2022-08-31 22:59:38 -04:00
|
|
|
#ifndef CRASH_HANDLER_H
|
|
|
|
#define CRASH_HANDLER_H
|
|
|
|
|
|
|
|
#ifdef __linux__
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
void SetupHandlerLinux(void);
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2022-09-03 01:15:43 -04:00
|
|
|
#elif _WIN32 // __linux__ ^^^^ _WIN32 vvvvv
|
|
|
|
#include <windows.h>
|
|
|
|
#include <DbgHelp.h>
|
2022-08-31 22:59:38 -04:00
|
|
|
|
2022-09-03 01:15:43 -04:00
|
|
|
#include <inttypes.h>
|
|
|
|
#include <excpt.h>
|
|
|
|
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
LONG seh_filter(struct _EXCEPTION_POINTERS* ex);
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#pragma comment(lib, "Dbghelp.lib")
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif // CRASH_HANDLER_H
|