preliminary google crashpad integration
First attempt at automated out-of-process crash reporting. Have only updated AppVeyor script so far, so if this works (which it won't), it'll only work on Windows.
This commit is contained in:
+12
-4
@@ -32,17 +32,18 @@ extern "C" {
|
||||
}
|
||||
|
||||
#include <csignal>
|
||||
|
||||
#include <QApplication>
|
||||
#include <QSurfaceFormat>
|
||||
|
||||
#include "core.h"
|
||||
#include "common/crashhandler.h"
|
||||
#include "common/debug.h"
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
signal(SIGSEGV, OLIVE_NAMESPACE::crash_handler);
|
||||
signal(SIGABRT, OLIVE_NAMESPACE::crash_handler);
|
||||
#ifdef USE_CRASHPAD
|
||||
#include "common/crashpadinterface.h"
|
||||
#endif // USE_CRASHPAD
|
||||
|
||||
int main(int argc, char *argv[]) {
|
||||
// Set OpenGL display profile (3.2 Core)
|
||||
QSurfaceFormat format;
|
||||
format.setVersion(3, 2);
|
||||
@@ -86,5 +87,12 @@ int main(int argc, char *argv[]) {
|
||||
avfilter_register_all();
|
||||
#endif
|
||||
|
||||
// Enable Google Crashpad if compiled with it
|
||||
#ifdef USE_CRASHPAD
|
||||
if (!InitializeCrashpad()) {
|
||||
qWarning() << "Failed to initialize Crashpad handler";
|
||||
}
|
||||
#endif // USE_CRASHPAD
|
||||
|
||||
return OLIVE_NAMESPACE::Core::instance()->execute(&a);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user