aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlpropertycache.cpp
diff options
context:
space:
mode:
authorAlan Alpert <alan.alpert@nokia.com>2012-05-08 16:48:30 +1000
committerQt by Nokia <qt-info@nokia.com>2012-06-25 08:57:36 +0200
commit046819ff4d53241d3b22cdb1d4abccad041bee6d (patch)
tree16014e8651ee6c643fd5674a584073df7b8cb07a /src/qml/qml/qqmlpropertycache.cpp
parent40bb33103b0ad1b630cbcdb0449a6b8cd88d95df (diff)
Don't Assert
It's better to have run-time errors in certain uses of the property than to assert when trying to access it. Change-Id: I913eea3fe275ee41358ac8d56bd597faf8e613ad Reviewed-by: Chris Adams <christopher.adams@nokia.com> Reviewed-by: Andrew Stanley-Jones <andrew.stanley-jones@nokia.com>
Diffstat (limited to 'src/qml/qml/qqmlpropertycache.cpp')
-rw-r--r--src/qml/qml/qqmlpropertycache.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/qml/qml/qqmlpropertycache.cpp b/src/qml/qml/qqmlpropertycache.cpp
index 87e707d1a0..d922b9942a 100644
--- a/src/qml/qml/qqmlpropertycache.cpp
+++ b/src/qml/qml/qqmlpropertycache.cpp
@@ -210,7 +210,8 @@ void QQmlPropertyData::lazyLoad(const QMetaMethod &m)
propType = QMetaType::Void;
const char *returnType = m.typeName();
- Q_ASSERT(returnType != 0);
+ if (!returnType)
+ returnType = "\0";
if ((*returnType != 'v') || (qstrcmp(returnType+1, "oid") != 0)) {
propTypeName = returnType;
flags |= NotFullyResolved;