Details
-
Bug
-
Resolution: Invalid
-
Not Evaluated
-
None
-
4.8.0
-
None
-
i686-pc-linux-gnu; linux-3.1.6, binutils-2.21.1a, gcc-4.6.2, glib-2.14.1, Qt-4.7.4 or Qt-4.8.0, KDE-4.7.4
Description
There exist cases where one connects the destroyed() signal to a slot in which deleteLater() calls are made or triggered. In such cases, as deleteLater() calls are not processed until the (event) loopLevel drops below the current level (which is often (always?) 1 here), the deferred deletions may not be done until the application exits. This issue is now occurring in KDE-4.7.X.
The attached patch addresses this issue by incrementing loopLevel specifically for the
'emit destroyed()' signal in src/corelib/kernel/qobject.cpp
I realize this is a bit of a hack, and may not be the proper way to handle this, but
hopefully it will spur discussion and resolution of the issue.
Attachments
Issue Links
- relates to
-
QTBUG-23369 Qt behaviour of deleteLater() triggering another deleteLater() via destroyed() signal
- Closed