diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-05-06 00:56:28 (GMT) |
---|---|---|
committer | Aaron Kennedy <aaron.kennedy@nokia.com> | 2009-05-06 01:01:17 (GMT) |
commit | 547223a4f31067ed34acabd9a2d8a0b7645fd3f8 (patch) | |
tree | b4e676646c7f9b569428784d255c22fdca9467df /src/declarative/qml/qmlparser.cpp | |
parent | b291ab1f5ebb496d7eb7aae04c3f06d57a4f547d (diff) | |
download | Qt-547223a4f31067ed34acabd9a2d8a0b7645fd3f8.zip Qt-547223a4f31067ed34acabd9a2d8a0b7645fd3f8.tar.gz Qt-547223a4f31067ed34acabd9a2d8a0b7645fd3f8.tar.bz2 |
Fix crash
As QMetaObject::indexOfProperty() downcasts QMetaObject's that have the DynamicMetaObject flag set, we must ensure that we use a QAbstractDynamicMetaObject whereever we set this flag, otherwise it may crash.
Diffstat (limited to 'src/declarative/qml/qmlparser.cpp')
-rw-r--r-- | src/declarative/qml/qmlparser.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/declarative/qml/qmlparser.cpp b/src/declarative/qml/qmlparser.cpp index a943c4d..d68eb68 100644 --- a/src/declarative/qml/qmlparser.cpp +++ b/src/declarative/qml/qmlparser.cpp @@ -63,7 +63,7 @@ QT_BEGIN_NAMESPACE using namespace QmlParser; QmlParser::Object::Object() -: type(-1), metatype(0), extObject(0), defaultProperty(0), line(-1), column(-1) +: type(-1), metatype(0), extObjectData(0), defaultProperty(0), line(-1), column(-1) { } @@ -76,8 +76,8 @@ QmlParser::Object::~Object() const QMetaObject *Object::metaObject() const { - if (extObject && metatype) - return extObject; + if (extObjectData && metatype) + return &extObject; else return metatype; } |