Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.2.0 Beta1
-
None
-
X11, latest qt5-release
-
2331a5ef5765d1b99472cd05e1af4b84d59c0177
Description
Running the following test case on Linux (just move the mouse cursor around to create self-closing child windows), it typically takes a few tens of child windows to trigger a deadlock. See the attached backtrace for details.
The same problem is also easy to reproduce with the QtQuick Controls gallery by hovering the menubar items back and forth to show and hide menus.
#include <QtQuick> class MyWindow : public QQuickWindow { protected: void mouseMoveEvent(QMouseEvent *ev) { static QPoint lastPos = ev->pos(); if (QPoint(lastPos - ev->pos()).manhattanLength() > 50) { QQuickWindow* child = new QQuickWindow; child->setTransientParent(this); child->setFlags(Qt::Popup); child->resize(100, 100); child->show(); QTimer::singleShot(100, child, SLOT(close())); QTimer::singleShot(1000, child, SLOT(deleteLater())); static int i = 0; qDebug() << ++i; } } }; int main(int argc, char *argv[]) { QGuiApplication a(argc, argv); MyWindow window; window.resize(320, 240); window.show(); return a.exec(); }
Doesn't happen with QML_BAD_GUI_RENDER_LOOP or on Windows.