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

crash in QQuickDesignerSupport with gcc at ubuntu

    XMLWordPrintable

Details

    Description

      looks like https://codereview.qt-project.org/c/qt/qtdeclarative/+/327084 reintroduce an already fixed problem from Fawzi: https://codereview.qt-project.org/c/qt/qtdeclarative/+/310218

      1  QtPrivate::indexOf<QObject *, QObject *>                               qlist.h                             190 0x7f59bbeb3940 
      2  QListSpecialMethodsBase<QObject *>::indexOf<QObject *>                 qlist.h                             897 0x7f59bbeb3940 
      3  QListSpecialMethodsBase<QObject *>::contains<QObject *>                qlist.h                             80  0x7f59bbeb3940 
      4  QQuickDesignerSupportProperties::propertyNameListForWritableProperties qquickdesignersupportproperties.cpp 140 0x7f59bbeb3940 
      5  QQuickDesignerCustomObjectData::populateResetHashes                    qquickdesignercustomobjectdata.cpp  178 0x7f59bbea7f21 
      6  QQuickDesignerCustomObjectData::QQuickDesignerCustomObjectData         qquickdesignercustomobjectdata.cpp  65  0x7f59bbea856d 
      7  QmlDesigner::Internal::QmlPrivateGate::registerCustomData              qmlprivategate_56.cpp               254 0x563a1d3b65d2 
      8  QmlDesigner::Internal::ObjectNodeInstance::populateResetHashes         objectnodeinstance.cpp              915 0x563a1d36b7b4 
      9  QmlDesigner::Internal::QuickItemNodeInstance::create                   quickitemnodeinstance.cpp           157 0x563a1d3a503a 
      10 QmlDesigner::ServerNodeInstance::createInstance                        servernodeinstance.cpp              184 0x563a1d3ab179 
      11 QmlDesigner::ServerNodeInstance::create                                servernodeinstance.cpp              265 0x563a1d3ac0b4 
      12 QmlDesigner::NodeInstanceServer::createInstances                       nodeinstanceserver.cpp              209 0x563a1d32e23b 
      13 QmlDesigner::NodeInstanceServer::setupInstances                        nodeinstanceserver.cpp              574 0x563a1d330dd5 
      14 QmlDesigner::Qt5NodeInstanceServer::setupScene                         qt5nodeinstanceserver.cpp           167 0x563a1d39c780 
      15 QmlDesigner::Qt5PreviewNodeInstanceServer::createScene                 qt5previewnodeinstanceserver.cpp    52  0x563a1d39f9ab 
      16 QmlDesigner::NodeInstanceClientProxy::createScene                      nodeinstanceclientproxy.cpp         409 0x563a1d2e2724 
      17 QmlDesigner::NodeInstanceClientProxy::dispatchCommand                  nodeinstanceclientproxy.cpp         541 0x563a1d2e351f 
      18 QmlDesigner::NodeInstanceClientProxy::readDataStream                   nodeinstanceclientproxy.cpp         378 0x563a1d2e255a 
      
      

      one possible solution could be not assigning something local to an argument

      QQuickDesignerSupport::PropertyNameList QQuickDesignerSupportProperties::propertyNameListForWritableProperties(QObject *object,
                                                             const QQuickDesignerSupport::PropertyName &baseName,
                                                             QObjectList *globalInspectedObjects)
      {
          QQuickDesignerSupport::PropertyNameList propertyNameList;
      
          QObjectList localObjectList;
          QObjectList *inspectedObjects = globalInspectedObjects ? globalInspectedObjects : &localObjectList;
      
          if (!inspectedObjects->contains(object))
              inspectedObjects->append(object);
      

      another idea would be to add volatile to "localObjectList"

      still unsure about Miikkas patch itself, because it removes possible loops, no idea how to create such a loop and the code was existing since 2015

      Now the patch from Miikka is already in 5.15.3 which is in use since QtDesignStudio 2.1.0 is out.

      Attachments

        Issue Links

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

          Activity

            People

              tjenssen Tim Jenssen
              tjenssen Tim Jenssen
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes