Details
-
Bug
-
Resolution: Done
-
P1: Critical
-
5.0.2, 5.1.1, 5.2.0 Beta1
-
None
-
I've been able to reproduce this crash with Qt 5.1.1 and Qt 5.2.0 Beta 1 on Arch Linux x86_64 and with Qt 5.0.2 on Windows XP 32-bit. The stacktrace is from Qt 5.1.1 on Arch Linux.
Description
SpringAnimation crashes when it completes and is used in ListView's Transition. This happens always when ListView's model has more than one item. It doesn't crash when the model doesn't have multiple items.
crash.qml
import QtQuick 2.0 Rectangle { width: 250 height: 250 ListView { anchors.fill: parent model: ListModel { ListElement { text: "A" } ListElement { text: "B" } } populate: Transition { SpringAnimation { properties: "x"; from: -100; to: 0; spring: 4; damping: 0.3 } } delegate: Text { text: "Test" } } }
The crash happens because in QSpringAnimation::updateCurrentTime at util/qquickspringanimation.cpp:311, animationTemplate is NULL but still dereferenced.