Skip to content

Commit 9e2293f

Browse files
committed
Don't let CRT's exit() bypass the final JSC::Options::dumpAllOptions()
1 parent 1ecf28e commit 9e2293f

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

src/browserapplication.cpp

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -186,11 +186,6 @@ BrowserApplication::BrowserApplication(int &argc, char **argv)
186186

187187
BrowserApplication::~BrowserApplication()
188188
{
189-
if (jscoptions) {
190-
// once again, to see if something changed behind the scenes
191-
JSC::Options::dumpAllOptions(stdout);
192-
fflush(stdout);
193-
}
194189
quitting = true;
195190
delete s_downloadManager;
196191
qDeleteAll(m_mainWindows);
@@ -331,6 +326,13 @@ void BrowserApplication::quitBrowser()
331326
}
332327

333328
saveSession();
329+
330+
if (jscoptions) {
331+
// once again, to see if something changed behind the scenes
332+
JSC::Options::dumpAllOptions(stdout);
333+
fflush(stdout);
334+
}
335+
334336
::exit(0); // desperately ensure to not leave a zombie process, as occasionally observed with Qt's exit()
335337
}
336338

0 commit comments

Comments
 (0)