Prevent a crash when the item is deleted but not removed from cache
authorAndy Shaw <andy.shaw@digia.com>
Thu, 17 Apr 2014 08:24:35 +0000 (10:24 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Fri, 18 Apr 2014 05:39:17 +0000 (07:39 +0200)
commit2776d48b7a1586518e9add43f723ecc6987f4418
tree7914e9d7067ac6a45f21f645f9ac6ed52e0e8265
parent37e4975e5f43a85e81109b115bfe10d371d0bf89
Prevent a crash when the item is deleted but not removed from cache

If the item is not removed from the cache when it is deleted then the
cache can end up pointing to an invalid item which when accessed will
cause a crash.

Task-number: QTBUG-38430

[ChangeLog][QtQml] Prevent a crash when the item is deleted
but is not removed from the QQmlDelegateModel's cache.

Change-Id: I8cf76b014be62a432d909a3573231cec84a6d678
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
src/qml/types/qqmldelegatemodel_p_p.h