[Issue N8316] Bug in eventloop handling in KDE's qt-copy (half a day old)

qt-bugs at trolltech.com qt-bugs at trolltech.com
Mon Oct 14 08:19:25 BST 2002


On Sunday, 13 Oct 2002 2:24 Joseph Wenninger wrote:
>
> Hi

Hello Joseph,

> I think I found a bug in the enterLoop method. I have an application,
> which uses excessivly enter_loop, exit_loop, which worked perfect with
> Qt 3.0.x, but doesn't work anymore with Qt 3.1 beta X. The application
> is quanta in the KDE's cvs reprository. The application always exited,
> although the application event loop still existed and only the first
> sub event loop should be left.
>
> If I compare the code from Qt 3.0.5 and 3.1 beta, I think (and tested)
> that the following patch should fix the problem, and I can't see any
> negative side effects.

This patch is correct.  I have applied the fix for the next 3.1.0
beta/release.

Thanks for the report :)

> Kind regards
> Joseph Wenninger
>
> ==================================================================
> RCS file: /home/kde/qt-copy/src/kernel/qeventloop.cpp,v
> retrieving revision 1.5
> diff -u -3 -p -r1.5 qeventloop.cpp
> --- src/kernel/qeventloop.cpp   2002/10/09 12:34:07     1.5
> +++ src/kernel/qeventloop.cpp   2002/10/12 23:12:59
> @@ -192,7 +192,7 @@ int QEventLoop::enterLoop()
>      // exitloop set so that all other event loops drop out.
>      d->exitloop = old_exitloop || d->quitnow;
>
> -    if ( d->looplevel <= 1 ) {
> +    if ( d->looplevel < 1 ) {
>         d->quitnow = FALSE;
>         d->exitloop = FALSE;
>         emit qApp->aboutToQuit();
>

--
Bradley T Hughes
Trolltech AS, Waldemar Thranes gt. 98, N-0175 Oslo, Norway





More information about the kde-core-devel mailing list