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

Crash in QQuickAnimatorController::beforeNodeSync

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 5.3.0
    • 5.2.1, 5.3.1, 5.4.0
    • Quick: SceneGraph
    • None
    • 8f3311276e4ca44acb69c8870ccfc3167682b898

    Description

      I get this crash with my app ( https://github.com/aportale/qtouchandlearn ) :

      Thread 2 (Thread 10603.10638):
      #0  0x6ba8b464 in QPODVector<QAbstractAnimationJob::ChangeListener, 1>::append (this=0x28, v=...) at /home/aportale/dev/qt5_readonly/qtbase/include/QtQml/5.3.0/QtQml/private/../../../../../../qtdeclarative/src/qml/qml/ftw/qpodvector_p.h:86
      No locals.
      #1  0x6ba8aba8 in QAbstractAnimationJob::addAnimationChangeListener (this=0x0, listener=0x688cf9d8, changes=...) at animations/qabstractanimationjob.cpp:631
      No locals.
      #2  0x6bd27e5c in QQuickAnimatorController::beforeNodeSync (this=0x688cf9d0) at util/qquickanimatorcontroller.cpp:149
              job = 0x0
              proxy = 0x69fba068
              _container_ = {c = {{d = 0x6a080128, e = 0x6a080128}}, brk = 0, i = {i = 0x6a0e2ad8}, e = {i = 0x6a080128}}
      #3  0x6bdd6eac in QQuickWindowPrivate::syncSceneGraph (this=0x6887c900) at items/qquickwindow.cpp:335
              _qml_memory_scope = {pushed = false}
              q = 0x688cf440
              mode = {i = 1754068032}
      #4  0x6bd9ce44 in QSGGuiThreadRenderLoop::renderWindow (this=0x688cf678, window=0x688cf440) at scenegraph/qsgrenderloop.cpp:363
              cd = 0x6887c900
              data = @0x6896856c
              current = true
              alsoSwap = true
              renderTime = 0
              swapTime = 7702347973962184348
              __PRETTY_FUNCTION__ = "void QSGGuiThreadRenderLoop::renderWindow(QQuickWindow*)"
              syncTime = 0
              renderTimer = {t1 = 7536317577819534972, t2 = 7536357400756303492}
              profileFrames = false
      #5  0x6bd9d660 in QSGGuiThreadRenderLoop::event (this=0x688cf678, e=0x6c7737a8) at scenegraph/qsgrenderloop.cpp:464
              data = @0x6896856c
              it = {i = 0x68968560}
      #6  0x6adf75f4 in QCoreApplicationPrivate::notify_helper (this=0x66e37d98, receiver=0x688cf678, event=0x6c7737a8) at kernel/qcoreapplication.cpp:1052
      No locals.
      #7  0x6adf71d4 in QCoreApplication::notify (this=0x6c773918, receiver=0x688cf678, event=0x6c7737a8) at kernel/qcoreapplication.cpp:997
              d = 0x66e37d98
              __PRETTY_FUNCTION__ = "virtual bool QCoreApplication::notify(QObject*, QEvent*)"
      #8  0x6b15a380 in QGuiApplication::notify (this=0x6c773918, object=0x688cf678, event=0x6c7737a8) at kernel/qguiapplication.cpp:1457
      No locals.
      #9  0x6adf70c4 in QCoreApplication::notifyInternal (this=0x6c773918, receiver=0x688cf678, event=0x6c7737a8) at kernel/qcoreapplication.cpp:935
              threadData = 0x415d7848
              loopLevelCounter = {threadData = 0x415d7848}
              result = false
              cbdata = {0x688cf678, 0x6c7737a8, 0x6c773747}
              d = 0x68735a08
      #10 0x6adf46cc in QCoreApplication::sendEvent (receiver=0x688cf678, event=0x6c7737a8) at kernel/qcoreapplication.h:237
      No locals.
      #11 0x6ae878f8 in QTimerInfoList::activateTimers (this=0x66f86e88) at kernel/qtimerinfo_unix.cpp:643
              e = {<QEvent> = {_vptr.QEvent = 0x6b09e6c8, static staticMetaObject = {d = {superdata = 0x0, stringdata = 0x6b02507c, data = 0x6b0264dc, static_metacall = 0, relatedMetaObjects = 0x0, extradata = 0x0}}, d = 0x0, t = 1, posted = 0, spont = 0, m_accept = 1, reserved = 3470}, id = 3}
              currentTimerInfo = 0x0
              n_act = 2
              maxCount = 1
              currentTime = {tv_sec = 38074, tv_nsec = 236369850}
      #12 0x6ae84e40 in QEventDispatcherUNIX::activateTimers (this=0x6846cf00) at kernel/qeventdispatcher_unix.cpp:557
              d = 0x66f86800
      #13 0x6ae8523c in QEventDispatcherUNIX::processEvents (this=0x6846cf00, flags=...) at kernel/qeventdispatcher_unix.cpp:619
              tm = 0x6c773800
              wait_tm = {tv_sec = 0, tv_nsec = 0}
              d = 0x66f86800
              nevents = 1
              canWait = false
      #14 0x685dba44 in QUnixEventDispatcherQPA::processEvents (this=0x6846cf00, flags=...) at eventdispatchers/qunixeventdispatcher.cpp:70
              didSendEvents = 65
      #15 0x6adf2da4 in QEventLoop::processEvents (this=0x6c773890, flags=...) at kernel/qeventloop.cpp:136
              d = 0x69f97468
      #16 0x6adf3110 in QEventLoop::exec (this=0x6c773890, flags=...) at kernel/qeventloop.cpp:212
              locker = {val = 1726183600}
              __PRETTY_FUNCTION__ = "int QEventLoop::exec(QEventLoop::ProcessEventsFlags)"
              ref = {d = 0x69f97468, locker = @0x6c773854, exceptionCaught = true}
              app = 0x6c773918
              d = 0x69f97468
      #17 0x6adf79c8 in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1188
              threadData = 0x415d7848
              __PRETTY_FUNCTION__ = "static int QCoreApplication::exec()"
              eventLoop = {<QObject> = {_vptr.QObject = 0x6b09ffd8, static staticMetaObject = {d = {superdata = 0x0, stringdata = 0x6afc3ef8, data = 0x6afc3fd0, static_metacall = 0x6ae4cc1c <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x69f97468}, static staticQtMetaObject = {d = {superdata = 0x0, stringdata = 0x6b012490, data = 0x6b01a1bc, static_metacall = 0, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = 0x6b09e750, stringdata = 0x6b024ca8, data = 0x6b024cec, static_metacall = 0x6aefac4c <QEventLoop::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}
              returnCode = 1796443624
      #18 0x6b15a280 in QGuiApplication::exec () at kernel/qguiapplication.cpp:1436
      No locals.
      #19 0x6c1962dc in main (argc=1, argv=0x6c773998) at ../src/main.cpp:67
              app = {<QCoreApplication> = {<QObject> = {_vptr.QObject = 0x6b594cf8, static staticMetaObject = {d = {superdata = 0x0, stringdata = 0x6afc3ef8, data = 0x6afc3fd0, static_metacall = 0x6ae4cc1c <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x66e37d98}, static staticQtMetaObject = {d = {superdata = 0x0, stringdata = 0x6b012490, data = 0x6b01a1bc, static_metacall = 0, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = 0x6b09e750, stringdata = 0x6b024da4, data = 0x6b024f54, static_metacall = 0x6aefae60 <QCoreApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, static self = 0x6c773918}, static staticMetaObject = {d = {superdata = 0x6b0a0018, stringdata = 0x6b4f3c40, data = 0x6b4f3f88, static_metacall = 0x6b161388 <QGuiApplication::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}
              translation = {static null = {<No data fields>}, d = 0x66f885d0}
              assetsPrefix = {static null = {<No data fields>}, d = 0x6c1a3938}
              translator = {<QObject> = {_vptr.QObject = 0x6b0a01c8, static staticMetaObject = {d = {superdata = 0x0, stringdata = 0x6afc3ef8, data = 0x6afc3fd0, static_metacall = 0x6ae4cc1c <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x66f88be0}, static staticQtMetaObject = {d = {superdata = 0x0, stringdata = 0x6b012490, data = 0x6b01a1bc, static_metacall = 0, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = 0x6b09e750, stringdata = 0x6b026f30, data = 0x6b026f4c, static_metacall = 0x6aefc220 <QTranslator::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}
              engine = {<QQmlEngine> = {<QJSEngine> = {<QObject> = {_vptr.QObject = 0x6bbf6f70, static staticMetaObject = {d = {superdata = 0x0, stringdata = 0x6afc3ef8, data = 0x6afc3fd0, static_metacall = 0x6ae4cc1c <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x68399538}, static staticQtMetaObject = {d = {superdata = 0x0, stringdata = 0x6b012490, data = 0x6b01a1bc, static_metacall = 0, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = 0x6b09e750, stringdata = 0x6baec430, data = 0x6baec44c, static_metacall = 0x6b845e78 <QJSEngine::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d = 0x6839a0b8}, static staticMetaObject = {d = {superdata = 0x6bbf43d8, stringdata = 0x6bb85dc0, data = 0x6bb85e60, static_metacall = 0x6bacdfb4 <QQmlEngine::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = 0x6bbf81d0, stringdata = 0x6bb7429c, data = 0x6bb74398, static_metacall = 0x6ba2d1a0 <QQmlApplicationEngine::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}}
              mainQml = {static null = {<No data fields>}, d = 0x6c1a39e8}
              dataPath = {static null = {<No data fields>}, d = 0x625c9af8}
              settings = {<QObject> = {_vptr.QObject = 0x6c301b78, static staticMetaObject = {d = {superdata = 0x0, stringdata = 0x6afc3ef8, data = 0x6afc3fd0, static_metacall = 0x6ae4cc1c <QObject::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, d_ptr = {d = 0x66f88908}, static staticQtMetaObject = {d = {superdata = 0x0, stringdata = 0x6b012490, data = 0x6b01a1bc, static_metacall = 0, relatedMetaObjects = 0x0, extradata = 0x0}}}, static staticMetaObject = {d = {superdata = 0x6b09e750, stringdata = 0x6c2fe158, data = 0x6c2fe1f8, static_metacall = 0x6c1a32bc <Settings::qt_static_metacall(QObject*, QMetaObject::Call, int, void**)>, relatedMetaObjects = 0x0, extradata = 0x0}}, m_settings = 0x66e16fd0}
      #20 0x6857622c in startMainMethod () at androidjnimain.cpp:442
              params = {a = 256, s = 1, ptr = 0x6c773998, {array = "pz\343f", '\000' <repeats 973 times>, "0\341fW\r\034@\000\000\000\000\000\000\000\000\003\000\000\000\270z\343f\000\000\000\000\004aWh\000\000\000\000\244\261\033@\000\000\000\000\000\000\000", q_for_alignment_1 = 1726184048, q_for_alignment_2 = 8.5284823651597732e-315}}
              ret = 0
              __PRETTY_FUNCTION__ = "void* startMainMethod(void*)"
              env = {attached = false, jniEnv = 0x0}
      #21 0x401bb22c in __thread_entry () from /home/aportale/qtouchandlearn/build-touchandlearn-Android_for_armeabi_v7a_GCC_4_8_Qt_5_3_0_Qt_5_3_0_qt5_readonly-Debug/libc.so
      No symbol table info available.
      #22 0x401bb3c4 in pthread_create () from /home/aportale/qtouchandlearn/build-touchandlearn-Android_for_armeabi_v7a_GCC_4_8_Qt_5_3_0_Qt_5_3_0_qt5_readonly-Debug/libc.so
      No symbol table info available.
      #23 0x00000000 in ?? ()
      No symbol table info available.
      

      And this is the scenario: The source of a Loader element is changed from one qml file to another. The crash happens if the previously qml "sub-scene" had an animation running while being unloaded. perhaps the new replacement "sub-scene" also needs to do something special, in my case it has a flickable list.
      QQuickAnimatorController::beforeNodeSync seems to get a 0-pointer from the proxy and seems to access it.

      If needed and the above backtrace does not help, I can try to isolate the part of my app which reproduces the crash.

      The btrace above shows the crash with the basic rendering loop on Android. It is similar with the threaded one. ANd it is similar on Desktop (MinGW).

      Edit: This description originally siad that this is only reproducible on Android, but I am also able to reproduce it on Desktop.

      Attachments

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

        Activity

          People

            sletta Gunnar Sletta
            portale Alessandro Portale
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes