aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlpropertycache.cpp
diff options
context:
space:
mode:
authorDmitry Volosnykh <dmitry.volosnykh@gmail.com>2015-05-21 10:52:49 +0300
committerDmitry Volosnykh <dmitry.volosnykh@gmail.com>2015-06-25 21:51:21 +0000
commit5c90bf6777016e07fd0c46bcbdb9ca759c028e16 (patch)
treef706a115df15f130d8c46dcf9bbe664a844d71cf /src/qml/qml/qqmlpropertycache.cpp
parent29ecb180523869e746ff43a523a16eb4bae918f2 (diff)
Clear stringCache explicitly instead of asserting its emptiness.
This assumption does not hold when PathView's path.pathElements list is updated with new contents at runtime. Task-number: QTBUG-46255 Change-Id: I6b0d7ee8ee2d67ca0138eacdf0ad221338f788e4 Reviewed-by: Alan Alpert <aalpert@blackberry.com>
Diffstat (limited to 'src/qml/qml/qqmlpropertycache.cpp')
-rw-r--r--src/qml/qml/qqmlpropertycache.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/qml/qml/qqmlpropertycache.cpp b/src/qml/qml/qqmlpropertycache.cpp
index 168d038f9e..294f3ccdf9 100644
--- a/src/qml/qml/qqmlpropertycache.cpp
+++ b/src/qml/qml/qqmlpropertycache.cpp
@@ -837,7 +837,7 @@ void QQmlPropertyCache::updateRecur(const QMetaObject *metaObject)
void QQmlPropertyCache::update(const QMetaObject *metaObject)
{
Q_ASSERT(metaObject);
- Q_ASSERT(stringCache.isEmpty());
+ stringCache.clear();
// Preallocate enough space in the index caches for all the properties/methods/signals that
// are not cached in a parent cache so that the caches never need to be reallocated as this
@@ -862,7 +862,6 @@ void QQmlPropertyCache::update(const QMetaObject *metaObject)
*/
void QQmlPropertyCache::invalidate(const QMetaObject *metaObject)
{
- stringCache.clear();
propertyIndexCache.clear();
methodIndexCache.clear();
signalHandlerIndexCache.clear();