diff options
author | Aaron Kennedy <aaron.kennedy@nokia.com> | 2010-04-14 07:27:45 (GMT) |
---|---|---|
committer | Aaron Kennedy <aaron.kennedy@nokia.com> | 2010-04-14 08:49:19 (GMT) |
commit | 62b264e90a48997e1736d7a335bad99e2c52a50d (patch) | |
tree | 683cd6711510c414566384fba7e1777e703d5390 /src/declarative/qml/qdeclarativecomponent.cpp | |
parent | 6ae0b924102384d088c9a7f9b43170cf0d2668bd (diff) | |
download | Qt-62b264e90a48997e1736d7a335bad99e2c52a50d.zip Qt-62b264e90a48997e1736d7a335bad99e2c52a50d.tar.gz Qt-62b264e90a48997e1736d7a335bad99e2c52a50d.tar.bz2 |
Reduce warnings at shutdown
QTBUG-9799
Reviewed-by: Alexis Menard
Diffstat (limited to 'src/declarative/qml/qdeclarativecomponent.cpp')
-rw-r--r-- | src/declarative/qml/qdeclarativecomponent.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/declarative/qml/qdeclarativecomponent.cpp b/src/declarative/qml/qdeclarativecomponent.cpp index d319e8f..5f26ad5 100644 --- a/src/declarative/qml/qdeclarativecomponent.cpp +++ b/src/declarative/qml/qdeclarativecomponent.cpp @@ -597,6 +597,11 @@ QDeclarativeComponentPrivate::beginCreate(QDeclarativeContextData *context, cons return 0; } + if (!context->isValid()) { + qWarning("QDeclarativeComponent::beginCreate(): Cannot create a component in an invalid context"); + return 0; + } + if (context->engine != engine) { qWarning("QDeclarativeComponent::beginCreate(): Must create component in context from the same QDeclarativeEngine"); return 0; |