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

Item enable changes on unparenting leads to crash

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • None
    • 5.2.0
    • None
    • linux x86, qtdeclarative at aa6f324c0cea89238c4f557cf00d49ddc8acc4a9 .

    Description

      import QtQuick 2.0
      
      Item {
          id: root
          enabled: false
          Component {
              id: c
              MyItem { //C++ implementation connects enabledChanged() to setState("DEATH")
                  id: inner
                  property int foo: 3
                  states: [State {
                      name: "DEATH"
                      PropertyChanges { target: inner; foo: 9 }
                  }]
              }
          }
          Component.onCompleted: { c.createObject(root).destroy(); }
      }
      

      Leads to segfault.

      Note that specific timing is required, onEnabledChanged: inner.state = "DEATH" does not give the same effect.

      Attachments

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

        Activity

          People

            aalpert Alan Alpert
            aalpert Alan Alpert
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes