summaryrefslogtreecommitdiffstats
path: root/src/declarative/qml/qdeclarativecomponent.cpp
diff options
context:
space:
mode:
authorJørgen Lind <jorgen.lind@nokia.com>2010-03-11 08:21:15 (GMT)
committerJørgen Lind <jorgen.lind@nokia.com>2010-03-11 08:21:15 (GMT)
commit327c36acdba0422e93d99dc71cb3f5238d326977 (patch)
treed85c7b186af9a9324bb4acc5e36d630966876fee /src/declarative/qml/qdeclarativecomponent.cpp
parentb9f8c1491550fe671d1809481ad7f70737034a3b (diff)
parent16e8cc808ae7087aadd95855c97d715941711b45 (diff)
downloadQt-327c36acdba0422e93d99dc71cb3f5238d326977.zip
Qt-327c36acdba0422e93d99dc71cb3f5238d326977.tar.gz
Qt-327c36acdba0422e93d99dc71cb3f5238d326977.tar.bz2
Merge remote branch 'origin/4.7' into 4.7-lighthouse
Conflicts: src/gui/kernel/qapplication.cpp src/gui/kernel/qapplication_p.h src/gui/kernel/qwidget.cpp
Diffstat (limited to 'src/declarative/qml/qdeclarativecomponent.cpp')
-rw-r--r--src/declarative/qml/qdeclarativecomponent.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/declarative/qml/qdeclarativecomponent.cpp b/src/declarative/qml/qdeclarativecomponent.cpp
index 6a2d2d1..d6bb216 100644
--- a/src/declarative/qml/qdeclarativecomponent.cpp
+++ b/src/declarative/qml/qdeclarativecomponent.cpp
@@ -437,6 +437,13 @@ void QDeclarativeComponent::loadUrl(const QUrl &url)
else
d->url = url;
+ if (url.isEmpty()) {
+ QDeclarativeError error;
+ error.setDescription(tr("Invalid empty URL"));
+ d->state.errors << error;
+ return;
+ }
+
QDeclarativeCompositeTypeData *data =
QDeclarativeEnginePrivate::get(d->engine)->typeManager.get(d->url);