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

QQC2: Using ComboBox crashes

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P0: Blocker P0: Blocker
    • None
    • 6.0
    • Quick: Controls 2
    • None
    • Windows
    • 19874d6a6386b55fe502e3a36a9adb6813b315dc (qt/qtbase/dev)

      The following simple QML code crashes:

      import QtQuick 2.15
      import QtQuick.Controls 2.15
      
      ComboBox {
      	model: ListModel {}
      }
      
      Stacktrace
      1  QQmlListModel::index                     qqmllistmodel.cpp         2145 0x7ffb8c6840a6 
      2  QQuickComboBox::count                    qquickcombobox.cpp        919  0x7ffb843361f5 
      3  QQuickComboBox::componentComplete        qquickcombobox.cpp        2052 0x7ffb84339531 
      4  QQmlObjectCreator::finalize              qqmlobjectcreator.cpp     1467 0x7ffb88cd4417 
      5  QQmlComponentPrivate::complete           qqmlcomponent.cpp         990  0x7ffb88b752da 
      6  QQmlComponentPrivate::completeCreate     qqmlcomponent.cpp         1081 0x7ffb88b740ac 
      7  QQmlComponent::completeCreate            qqmlcomponent.cpp         1068 0x7ffb88b71e72 
      8  QQmlComponent::create                    qqmlcomponent.cpp         825  0x7ffb88b71bce 
      9  QQmlApplicationEnginePrivate::finishLoad qqmlapplicationengine.cpp 154  0x7ffb88cc255c 
      10 QQmlApplicationEnginePrivate::startLoad  qqmlapplicationengine.cpp 139  0x7ffb88cc1fe1 
      11 QQmlApplicationEngine::load              qqmlapplicationengine.cpp 283  0x7ffb88cc126d 
      12 main                                     main.cpp                  25   0x7ff65cb0333f 
      

      Qt Creator shows that the QModelIndex pointer is NULL:

      parent	0x0	QModelIndex*
      this	@0xc9641efaf8	QStringListModel
      

      The same happens with C++ models, e.g. QStringListModel.

      I'm building the dev branch for each Qt module and I think it stopped working around the middle of last week.

        For Gerrit Dashboard: QTBUG-86330
        # Subject Branch Project Status CR V

            fabiankosmale Fabian Kosmale
            mkrems Marcel Krems
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes