From 7687a640008d3eeeda736882ff5693cfa8f9e5b2 Mon Sep 17 00:00:00 2001 From: tildearrow Date: Sun, 29 May 2022 00:44:17 -0500 Subject: [PATCH] Revert "fire!" This reverts commit 7baf1d471f69e770a5792e9364376d0514711fdf. --- extern/backward/backward.hpp | 30 ++---------------------------- src/main.cpp | 8 +++----- 2 files changed, 5 insertions(+), 33 deletions(-) diff --git a/extern/backward/backward.hpp b/extern/backward/backward.hpp index b92a7b7f7..e778d58f3 100644 --- a/extern/backward/backward.hpp +++ b/extern/backward/backward.hpp @@ -4253,7 +4253,7 @@ public: } #ifdef _WIN32 - MessageBox(NULL,"Furnace has crashed! please report this to the issue tracker immediately:\r\nhttps://github.com/tildearrow/furnace/issues/new\r\n\r\na file called furnace_crash.txt will be created in your user directory.\r\nthis will be important for locating the origin of the crash.","Error",MB_OK|MB_ICONERROR); + MessageBox(NULL,"Error","Furnace has crashed! please report this to the issue tracker immediately:\r\nhttps://github.com/tildearrow/furnace/issues/new\r\n\r\na file called furnace_crash.txt will be created in your user directory.\r\nthis will be important for locating the origin of the crash.",MB_OK|MB_ICONERROR); std::string crashLocation; char* userProfile=getenv("USERPROFILE"); if (userProfile==NULL) { @@ -4284,7 +4284,7 @@ public: failedPrinter.print(st, str); str+="\r\ncould not open furnace_crash.txt!\r\nplease take a screenshot of this error message box!"; fprintf(stderr,"NOTICE: could not open furnace_crash.txt!\n"); - MessageBox(NULL,str.c_str(),"Error",MB_OK|MB_ICONERROR); + MessageBox(NULL,"Error",str.c_str(),MB_OK|MB_ICONERROR); #endif } @@ -4490,32 +4490,6 @@ private: printer.address = true; printer.print(st, std::cerr); - -#ifdef _WIN32 - MessageBox(NULL,"Furnace has crashed! please report this to the issue tracker immediately:\r\nhttps://github.com/tildearrow/furnace/issues/new\r\n\r\na file called furnace_crash.txt will be created in your user directory.\r\nthis will be important for locating the origin of the crash.","Error",MB_OK|MB_ICONERROR); - std::string crashLocation; - char* userProfile=getenv("USERPROFILE"); - if (userProfile==NULL) { - crashLocation="C:\\furnace_crash.txt"; - } else { - crashLocation=userProfile; - crashLocation+="\\furnace_crash.txt"; - } - FILE* crashDump=fopen(crashLocation.c_str(),"w"); -#else - FILE* crashDump=fopen("/tmp/furnace_crash.txt","w"); -#endif - - if (crashDump!=NULL) { - Printer printer; - printer.address = true; - printer.print(st, crashDump); - fclose(crashDump); - } else { -#ifdef _WIN32 - MessageBox(NULL,"could not do a crash dump!! :<","Error",MB_OK|MB_ICONERROR); -#endif - } } }; diff --git a/src/main.cpp b/src/main.cpp index 8cc01aa2a..995fa6f04 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -306,13 +306,11 @@ int main(int argc, char** argv) { } } -#ifdef _WIN32 if (!sh.loaded()) { - MessageBox(NULL,"crash backtrace not available!","Warning",MB_OK|MB_ICONWARNING); - } else { - MessageBox(NULL,"it will work","Notice",MB_OK|MB_ICONINFORMATION); - } +#ifdef _WIN32 + MessageBox(NULL,"Warning","crash backtrace not available!",MB_OK|MB_ICONWARNING); #endif + } e.setConsoleMode(consoleMode);