Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-54313

QQuickWidget: crash on application exit



    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • None
    • 5.5.1, 5.6.0, 5.6.1
    • Quick: Widget
    • None
    • Linux, MacOSX


      I have an application that has a welcome page written in QML with a QQuickWidget; when the user presses a button I'd like to switch to the main application view (like QtCreator does).
      I have a QMainWindow with a stack widget in which I put a QQuickWidget and my application widget.
      I trigger the switch between QQuickWidget and MyWidget from QML code. When I close the application I have a segfault deep inside Qt.

      In the attached example I made a minimal application that replicates the problem. I've seen that:

      • calling hide() on QQuickWidget from within QML code leads to a crash;
      • calling hide() on QQuickWidget from C++ code doesn't crash;

      Here is a sample stacktrace:

      1	QWidget::~QWidget()			0x1004c19ea	
      2	QWidget::~QWidget()			0x1004c255e	
      3	QV4::QObjectWrapper::destroyObject(bool)			0x1012fa826	
      4	QV4::MemoryManager::sweep(bool)			0x10119b5e0	
      5	QV4::MemoryManager::~MemoryManager()			0x10119c090	
      6	QV4::ExecutionEngine::~ExecutionEngine()			0x1012764d6	
      7	QV8Engine::~QV8Engine()			0x1013b93f8	
      8	QV8Engine::~QV8Engine()			0x1013b94fe	
      9	QJSEngine::~QJSEngine()			0x101222452	
      10	QQmlEngine::~QQmlEngine()			0x101325ccd	
      11	QQmlEngine::~QQmlEngine()			0x101325d1e	
      12	QObjectPrivate::deleteChildren()			0x101965f53	
      13	QWidget::~QWidget()			0x1004c1c3a	
      14	QQuickWidget::~QQuickWidget()			0x10001248c	
      15	QObjectPrivate::deleteChildren()			0x101965f53	
      16	QWidget::~QWidget()			0x1004c1c3a	
      17	QWidget::~QWidget()			0x1004c255e	
      18	QObjectPrivate::deleteChildren()			0x101965f53	
      19	QWidget::~QWidget()			0x1004c1c3a	
      20	MainWindow::~MainWindow()	mainwindow.h	11	0x100004585	
      21	MainWindow::~MainWindow()	mainwindow.h	11	0x100004565	
      22	main	main.cpp	11	0x1000044d2	
      23	start			0x100004454	


        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.



              tvete Paul Olav Tvete
              lucaotta Luca Ottaviano
              0 Vote for this issue
              1 Start watching this issue



                Gerrit Reviews

                  There are no open Gerrit changes