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

DialogButtonBox::test_attached fails

    XMLWordPrintable

Details

    Description

      Since https://codereview.qt-project.org/c/qt/qtdeclarative/+/290237 Items removed from a QQmlObjectModel don't automatically reset their visual parent anymore. Therefore, QQuickContainer does not get an itemParentChange() call anymore and retains references to stale items. Therefore

      1. We get use-after-free accesses when destroying the container
      2. The attached properties for DialogButtonBox are not cleared when clearing the model

      This leads to a test failure in qtquickcontrols2, as visible from https://codereview.qt-project.org/c/qt/qt5/+/290532:

       agent:2020/02/20 09:27:44 build.go:220: PASS   : tst_controls::Default::Dialog::cleanupTestCase()
       agent:2020/02/20 09:27:44 build.go:220: PASS   : tst_controls::Default::DialogButtonBox::initTestCase()
       agent:2020/02/20 09:27:44 build.go:220: FAIL!  : tst_controls::Default::DialogButtonBox::test_attached() Compared values are not the same
       agent:2020/02/20 09:27:44 build.go:220:    Actual   (): DialogButtonBox_QMLTYPE_104(0x7fe8de45c750)
       agent:2020/02/20 09:27:44 build.go:220:    Expected (): null
       agent:2020/02/20 09:27:44 build.go:220:    Loc: [/Users/qt/work/qt/qtquickcontrols2/tests/auto/controls/data/tst_dialogbuttonbox.qml(150)]
       agent:2020/02/20 09:27:44 build.go:220: make: *** [check] Segmentation fault: 11
      

      As this blocks the submodule update, it's a P0.

      Attachments

        Issue Links

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

          Activity

            People

              qt.team.quick.subscriptions Qt Quick and Widgets Team
              ulherman Ulf Hermann
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes