I Have a simple problem with Qt. At the start of my application I create a QApplication object.
Durring the application startup, in a particular case (but not always), before creating any windows and before calling QApplication::exec() I create QDialog, I call QDialog::exec() and then I exit the application. But just before I exit the application, I call QApplication::exec(). This will make my application to block and stay there forever. If I use the debugger I can see that it is blocked in file "qeventdispatcher_win.cpp" at the function: MsgWaitForMultipleObjectsEx(.....). Why is this happening? I know that I could remove the QApplication::exec() because after calling QDialog::exec(), I always want to quit the application. But isn't this a bad Qt practice? Why the blocking occurs? Any idea? Thanks a lot for your time!