On Thu, Dec 19, 2002 at 08:36:55PM +0100, Alfredo Braunstein wrote:
> On Qt:
> Open a document for which autosave is newer, so the popup appears. close the
> main window from the WM. Crash.
Here's the fix. Lars, OK ?
regards
john
Index: lyx_gui.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/frontends/qt2/lyx_gui.C,v
retrieving revision 1.26
diff -u -r1.26 lyx_gui.C
--- lyx_gui.C 18 Dec 2002 14:24:32 -0000 1.26
+++ lyx_gui.C 20 Dec 2002 00:29:42 -0000
@@ -51,6 +51,7 @@
#include <qpaintdevicemetrics.h>
#include <fcntl.h>
+#include <cstdlib>
#ifndef CXX_GLOBAL_CSTD
using std::exit;
@@ -165,7 +175,12 @@
void lyx_gui::exit()
{
- qApp->exit(0);
+ // we cannot call qApp->exit(0) - that could return us
+ // into a static dialog return in the lyx code (for example,
+ // load autosave file QMessageBox. We have to just get the hell
+ // out.
+
+ ::exit(0);
}
--
"ALL television is children's television."
- Richard Adler