<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Qt application does not terminate when QFileDialog is used]]></title><description><![CDATA[<p dir="auto">Hi everyone,</p>
<p dir="auto">I'm stuck in a weird behavior in Qt.</p>
<p dir="auto">I have a Qt project in windows where as soon as I use<br />
@QFileDialog::getOpenFileNames@</p>
<p dir="auto">then, exit the application, and the process keeps running in windows.<br />
This problem only occurs when I use Qt5.1.0-32bit in my 64bit PC.</p>
<p dir="auto">Everything works perfectly in Qt5.1.0-64 bit.</p>
<p dir="auto">I've tried to reinstall microsoft redistributable without success<br />
(I'm using VS2010 for 32 bit and VS2012 for 64 bit)</p>
<p dir="auto">I've also tried to call:<br />
@QApplication::exit(0);@</p>
<p dir="auto">but the application process does not stop.</p>
<p dir="auto">This is the stack once I exit the application and pause the debugger:<br />
@<br />
0 NtWaitForMultipleObjects ntdll32  0x7731015d<br />
1 WaitForMultipleObjectsEx KERNELBASE  0x750a15e9<br />
2 WaitForMultipleObjectsExImplementation kernel32  0x76bf19fc<br />
3 RealMsgWaitForMultipleObjectsEx USER32  0x7533086a<br />
4 CCliModalLoop::BlockFn callctrl.cxx 1222 0x76402bf1<br />
5 ModalLoop chancont.cxx 211 0x76402d31<br />
6 ThreadSendReceive channelb.cxx 4979 0x7651d2f6<br />
7 CRpcChannelBuffer::SwitchAptAndDispatchCall channelb.cxx 4454 0x7651d098<br />
8 CRpcChannelBuffer::SendReceive2 channelb.cxx 4076 0x7651cef0<br />
9 CCliModalLoop::SendReceive callctrl.cxx 899 0x76402cba<br />
10 CAptRpcChnl::SendReceive callctrl.cxx 583 0x76419aa1<br />
11 CCtxComChnl::SendReceive ctxchnl.cxx 734 0x76419b24<br />
12 NdrExtpProxySendReceive proxy.cxx 1932 0x7651ce06<br />
13 NdrpProxySendReceive RPCRT4  0x7567420b<br />
14 NdrClientCall2 RPCRT4  0x756f0149<br />
15 ObjectStublessClient stblsclt.cxx 474 0x7651c8e2<br />
16 ObjectStubless stubless.asm 154 0x764198ad<br />
17 RemoteReleaseRifRefHelper marshal.cxx 6770 0x7641b641<br />
18 RemoteReleaseRifRef marshal.cxx 6694 0x7641b5ed<br />
19 CStdMarshal::DisconnectCliIPIDs marshal.cxx 3964 0x7641b172<br />
20 CStdMarshal::Disconnect marshal.cxx 3273 0x7641a66e<br />
21 CStdIdentity::~CStdIdentity stdid.cxx 312 0x7641a817<br />
22 CStdIdentity::`scalar deleting destructor' ole32  0x7641a781<br />
23 CStdIdentity::CInternalUnk::Release stdid.cxx 767 0x7641aaf3<br />
24 IUnknown_Release_Proxy proxy.cxx 1773 0x7651d380<br />
25 FRMyRobots   0x50c44df<br />
26 LdrpCallInitRoutine ntdll32  0x773299a0<br />
27 LdrShutdownProcess ntdll32  0x7733d702<br />
28 RtlExitUserProcess ntdll32  0x7733d5a4<br />
29 ExitProcessStub kernel32  0x76bf79c4<br />
30 __crtExitProcess MSVCR100D  0x53fc859b<br />
31 __freeCrtMemory MSVCR100D  0x53fc8447<br />
32 exit MSVCR100D  0x53fc8092<br />
33 __tmainCRTStartup crtexe.c 568 0xc12f4a<br />
34 WinMainCRTStartup crtexe.c 371 0xc12cbf<br />
35 BaseThreadInitThunk kernel32  0x76bf336a<br />
36 __RtlUserThreadStart ntdll32  0x77329f72<br />
37 _RtlUserThreadStart ntdll32  0x77329f45<br />
@</p>
<p dir="auto">Does anyone know where this error comes from?<br />
Is this a bug?</p>
<p dir="auto">Thank you very much!</p>
]]></description><link>https://forum.qt.io/topic/34039/qt-application-does-not-terminate-when-qfiledialog-is-used</link><generator>RSS for Node</generator><lastBuildDate>Sat, 06 Jun 2026 19:53:43 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/34039.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 08 Nov 2013 01:45:51 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Wed, 13 Nov 2013 22:30:14 GMT]]></title><description><![CDATA[<p dir="auto">Sorry, I meant VS2010 SP1 :)<br />
I just edited the post.</p>
<p dir="auto">This is the link to the bug report:<br />
"<a href="https://bugreports.qt-project.org/browse/QTBUG-34790" target="_blank" rel="noopener noreferrer nofollow ugc">https://bugreports.qt-project.org/browse/QTBUG-34790</a>":<a href="https://bugreports.qt-project.org/browse/QTBUG-34790" target="_blank" rel="noopener noreferrer nofollow ugc">https://bugreports.qt-project.org/browse/QTBUG-34790</a></p>
]]></description><link>https://forum.qt.io/post/203979</link><guid isPermaLink="true">https://forum.qt.io/post/203979</guid><dc:creator><![CDATA[albert86]]></dc:creator><pubDate>Wed, 13 Nov 2013 22:30:14 GMT</pubDate></item><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Wed, 13 Nov 2013 04:46:21 GMT]]></title><description><![CDATA[<p dir="auto">You're welcome :)</p>
<p dir="auto">[quote]I already had VS2010 installed.[/quote]Original version, or SP1?</p>
<p dir="auto">[quote]I’ll then file a bug report.[/quote]Please post the link to the report here, so that others can follow it if they have the same issue.</p>
]]></description><link>https://forum.qt.io/post/203882</link><guid isPermaLink="true">https://forum.qt.io/post/203882</guid><dc:creator><![CDATA[JKSH]]></dc:creator><pubDate>Wed, 13 Nov 2013 04:46:21 GMT</pubDate></item><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Mon, 11 Nov 2013 16:10:09 GMT]]></title><description><![CDATA[<p dir="auto">Hi JKSH,<br />
I already had VS2010 SP1 (edited) installed. I never wondered why the window gets hidden after a QFileDialog is used. But I realised that you can quickly fix it raising your QWidget:<br />
@<br />
QStringList list = QFileDialog::getOpenFileNames();<br />
this-&gt;raise();<br />
@<br />
However it is not very fancy because the window gets hidden and then it comes to the top. I do not know of a better fix.</p>
<p dir="auto">The queued signal connection did not solve my problem...<br />
I'll then file a bug report.</p>
<p dir="auto">Thank you very much for all your help!</p>
]]></description><link>https://forum.qt.io/post/203659</link><guid isPermaLink="true">https://forum.qt.io/post/203659</guid><dc:creator><![CDATA[albert86]]></dc:creator><pubDate>Mon, 11 Nov 2013 16:10:09 GMT</pubDate></item><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Sun, 10 Nov 2013 05:30:31 GMT]]></title><description><![CDATA[<p dir="auto">I just remembered I don't have MSVC 2010 on my system anymore, sorry. I tried your example on MSVC 2012 x64 on Windows 8.1, and it quit properly. (However, when I closed the dialog, the main window also gets hidden behind Qt Creator. I think this is a bug).</p>
<p dir="auto">There have been other issues with Qt dialogs before (e.g. <a href="https://bugreports.qt-project.org/browse/QTBUG-32821" target="_blank" rel="noopener noreferrer nofollow ugc">https://bugreports.qt-project.org/browse/QTBUG-32821</a> ), but I don't know if your issue is related. This workaround helped me; you can try it:</p>
<h1>Rename your slot from <em>on_pushButton_clicked()</em> to something else, like <em>openDialog()</em>.</h1>
<p dir="auto">#In your MainWindow Constructor, make an explicit <em>queued connection</em>:<br />
@<br />
connect(ui-&gt;pushButton, SIGNAL(clicked()), this, SLOT(openDialog()), Qt::QueuedConnection);<br />
@</p>
<p dir="auto">Anyway, have you installed the Service Pack 1 for MSVC 2010? It came with some "bug fixes for the C++ compiler":<a href="http://support.microsoft.com/kb/983509" target="_blank" rel="noopener noreferrer nofollow ugc">http://support.microsoft.com/kb/983509</a> -- perhaps it was an issue with the MSVC compiler.</p>
<p dir="auto">Note: The SP1 installer has its quirks. If I remember correctly, I have to uninstall all VC++ 2010 Redistributables first.</p>
<p dir="auto">If these still doesn't resolve your issue, file a report at <a href="http://bugreports.qt-project.org/" target="_blank" rel="noopener noreferrer nofollow ugc">http://bugreports.qt-project.org/</a> (and attach your example one a .zip file, not a DropBox link)</p>
]]></description><link>https://forum.qt.io/post/203466</link><guid isPermaLink="true">https://forum.qt.io/post/203466</guid><dc:creator><![CDATA[JKSH]]></dc:creator><pubDate>Sun, 10 Nov 2013 05:30:31 GMT</pubDate></item><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Sat, 09 Nov 2013 15:37:25 GMT]]></title><description><![CDATA[<p dir="auto">I've just created a new GUI project from scratch, added a button in the MainWindow with the callback:</p>
<p dir="auto">@<br />
void MainWindow::on_pushButton_clicked(){<br />
QStringList list = QFileDialog::getOpenFileNames();<br />
}<br />
@</p>
<p dir="auto">I compile with VS2010 32 bit (Qt 5.1.1), press the button, click cancel on the filedialog and exit. And I have the same problem running on debug and release the call stack when I pause is the same, stopping at:</p>
<p dir="auto">@<br />
0 NtWaitForMultipleObjects ntdll32  0x7731015d<br />
@</p>
<p dir="auto">Everything works fine with the 64 bit version (VS2012).<br />
I've tried this in my 2 PC's running Windows 7 64 bits.</p>
<p dir="auto">The example is available "HERE":<a href="https://www.dropbox.com/sh/ryt2qi31859y3gl/2Pt4WWsG7u" target="_blank" rel="noopener noreferrer nofollow ugc">https://www.dropbox.com/sh/ryt2qi31859y3gl/2Pt4WWsG7u</a><br />
This must be either a problem with my 2 computers or a Qt bug...</p>
<p dir="auto">Thank you very much for your help,</p>
]]></description><link>https://forum.qt.io/post/203426</link><guid isPermaLink="true">https://forum.qt.io/post/203426</guid><dc:creator><![CDATA[albert86]]></dc:creator><pubDate>Sat, 09 Nov 2013 15:37:25 GMT</pubDate></item><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Sat, 09 Nov 2013 12:41:17 GMT]]></title><description><![CDATA[<p dir="auto">Hmm... I can't think of anything at this point. Can you post a "Short, Self Contained, Compilable Example":<a href="http://sscce.org/" target="_blank" rel="noopener noreferrer nofollow ugc">http://sscce.org/</a>? I'm happy to investigate a bit if you provide sample code.</p>
]]></description><link>https://forum.qt.io/post/203422</link><guid isPermaLink="true">https://forum.qt.io/post/203422</guid><dc:creator><![CDATA[JKSH]]></dc:creator><pubDate>Sat, 09 Nov 2013 12:41:17 GMT</pubDate></item><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Sat, 09 Nov 2013 05:01:06 GMT]]></title><description><![CDATA[<p dir="auto">Hello JKSH,</p>
<p dir="auto">Thanks a lot for your reply.</p>
<p dir="auto">I've just installed and tried the latest Qt 5.1.1 VS2010 OpenGL 32 bits and I have the same problem. When I pause in debug mode, it shows the same stack.</p>
<p dir="auto">Any hints?</p>
<p dir="auto">Thank you,</p>
]]></description><link>https://forum.qt.io/post/203407</link><guid isPermaLink="true">https://forum.qt.io/post/203407</guid><dc:creator><![CDATA[albert86]]></dc:creator><pubDate>Sat, 09 Nov 2013 05:01:06 GMT</pubDate></item><item><title><![CDATA[Reply to Qt application does not terminate when QFileDialog is used on Fri, 08 Nov 2013 02:33:22 GMT]]></title><description><![CDATA[<p dir="auto">Hi,</p>
<p dir="auto">Can you try again with Qt 5.1.1? It is fully backward-compatible with Qt 5.1.0 with many bug fixes.</p>
<p dir="auto"><a href="http://qt-project.org/downloads" target="_blank" rel="noopener noreferrer nofollow ugc">http://qt-project.org/downloads</a></p>
]]></description><link>https://forum.qt.io/post/203275</link><guid isPermaLink="true">https://forum.qt.io/post/203275</guid><dc:creator><![CDATA[JKSH]]></dc:creator><pubDate>Fri, 08 Nov 2013 02:33:22 GMT</pubDate></item></channel></rss>