In his Qt event loop, networking and I/O API talk, Thiago Macieira mentions that nesting of QEventLoop
's should be avoided:
QEventLoop is for nesting event Loops... Avoid it if you can because it creates a number of problems: things might reenter, new activations of sockets or timers that you were not expecting.
Can anybody expand on what he is referring to? I maintain a lot of code that uses modal dialogs which internally nest a new event loop when exec()
is called so I'm very interested in knowing what kind of problems this may lead to.