From: Aaron Kennedy Date: Fri, 7 Oct 2011 04:14:27 +0000 (+1000) Subject: Fix possible crash with an empty handle X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=fcfea59e30272ecabacb63c7dd4484fb9f04bc21;p=konrad%2Fqtdeclarative.git Fix possible crash with an empty handle Change-Id: I729c919692c65c0ab4272368b7c98101ef573545 Reviewed-on: http://codereview.qt-project.org/6204 Reviewed-by: Qt Sanity Bot Reviewed-by: Aaron Kennedy --- diff --git a/src/declarative/qml/qdeclarativeproperty.cpp b/src/declarative/qml/qdeclarativeproperty.cpp index 6e5e712..78c37de 100644 --- a/src/declarative/qml/qdeclarativeproperty.cpp +++ b/src/declarative/qml/qdeclarativeproperty.cpp @@ -1297,7 +1297,7 @@ bool QDeclarativePropertyPrivate::writeBinding(const QDeclarativeProperty &that, } \ - if (object && pp->valueType.valueTypeCoreIdx == -1) { + if (!isUndefined && object && pp->valueType.valueTypeCoreIdx == -1) { switch (type) { case QMetaType::Int: if (result->IsInt32())