Commit 6688b614 authored by Christian Kamm's avatar Christian Kamm
Browse files

QmlDump: Do not use an assert on something that can regularly fail.

Reviewed-by: Kai Koehne
parent ef963635
......@@ -161,7 +161,8 @@ static QtVersion *qtVersionForProject(ProjectExplorer::Project *project)
if (project && project->id() == QLatin1String("QmlProjectManager.QmlProject")) {
// We cannot access the QmlProject interfaces here, therefore use the metatype system
QTC_ASSERT(project->activeTarget() && project->activeTarget()->activeRunConfiguration(), return 0);
if (!project->activeTarget() || !project->activeTarget()->activeRunConfiguration())
return 0;
QVariant variant = project->activeTarget()->activeRunConfiguration()->property("qtVersionId");
QTC_ASSERT(variant.isValid() && variant.canConvert(QVariant::Int), return 0);
QtVersion *version = QtVersionManager::instance()->version(variant.toInt());
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment