X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcore%2Fapplication.cpp;h=cc9946cb32c7410a3f8e30fbd568728b55ee2c82;hb=d61601ce7f87044c8ddd1e097d8d8743f06e84b4;hp=bcb7e3de49e2cb0b3058844f2559f336cfdc5a50;hpb=20e1beb546c26eae3b1a61ab2051108a7dca221f;p=libs%2Fcore.git diff --git a/source/core/application.cpp b/source/core/application.cpp index bcb7e3d..cc9946c 100644 --- a/source/core/application.cpp +++ b/source/core/application.cpp @@ -62,6 +62,12 @@ int Application::run(int argc, char **argv, void *data) } catch(const exception &e) { + delete app_; + +#ifdef WIN32 + string msg=Debug::demangle(typeid(e).name())+":\n"+e.what(); + MessageBox(0, msg.c_str(), "Uncaught exception", MB_OK|MB_ICONERROR); +#else cerr<<"An uncaught exception occurred.\n"; cerr<<" type: "<file<<'\n'; } } +#endif - delete app_; return 124; } }