summaryrefslogtreecommitdiffstats
path: root/src/main.cpp
diff options
context:
space:
mode:
authorHowaner <franzi.moos@googlemail.com>2014-11-30 19:38:52 +0100
committerHowaner <franzi.moos@googlemail.com>2014-11-30 19:38:52 +0100
commit6adf749164d7bc98bf34173b1f9d64804913d734 (patch)
treee15bd9dd8512fdbb61736db4d2d0b1f218bb81f0 /src/main.cpp
parentRemoved old MobType category. (diff)
parentHopefully fixed random build fails (diff)
downloadcuberite-6adf749164d7bc98bf34173b1f9d64804913d734.tar
cuberite-6adf749164d7bc98bf34173b1f9d64804913d734.tar.gz
cuberite-6adf749164d7bc98bf34173b1f9d64804913d734.tar.bz2
cuberite-6adf749164d7bc98bf34173b1f9d64804913d734.tar.lz
cuberite-6adf749164d7bc98bf34173b1f9d64804913d734.tar.xz
cuberite-6adf749164d7bc98bf34173b1f9d64804913d734.tar.zst
cuberite-6adf749164d7bc98bf34173b1f9d64804913d734.zip
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp
index c60e13a8c..fe4b360a5 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -61,6 +61,7 @@ void NonCtrlHandler(int a_Signal)
std::signal(SIGSEGV, SIG_DFL);
LOGERROR(" D: | MCServer has encountered an error and needs to close");
LOGERROR("Details | SIGSEGV: Segmentation fault");
+ PrintStackTrace();
abort();
}
case SIGABRT:
@@ -71,6 +72,7 @@ void NonCtrlHandler(int a_Signal)
std::signal(a_Signal, SIG_DFL);
LOGERROR(" D: | MCServer has encountered an error and needs to close");
LOGERROR("Details | SIGABRT: Server self-terminated due to an internal fault");
+ PrintStackTrace();
abort();
}
case SIGINT:
@@ -137,6 +139,9 @@ LONG WINAPI LastChanceExceptionFilter(__in struct _EXCEPTION_POINTERS * a_Except
g_WriteMiniDump(GetCurrentProcess(), GetCurrentProcessId(), dumpFile, g_DumpFlags, (a_ExceptionInfo) ? &ExcInformation : nullptr, nullptr, nullptr);
CloseHandle(dumpFile);
+ // Print the stack trace for the basic debugging:
+ PrintStackTrace();
+
// Revert to old stack:
_asm
{