diff options
author | Daniel Teske <daniel.teske@digia.com> | 2014-07-31 16:36:46 +0200 |
---|---|---|
committer | Christian Stenger <christian.stenger@digia.com> | 2014-08-01 07:40:09 +0200 |
commit | 92cdd7045b48ea6140341f7f0cb0f591d2c0a351 (patch) | |
tree | 35868ed2795dba648e8cd27bbc38d6d51aeff076 | |
parent | 434389bd930d4e7b17a2099a1f51f092cf9f8755 (diff) |
CmakeProject: Don't crash on addKit + cancel
This was introduced by adding the remote linux support for 3.0 in
328a24edee3008a8d6bbbc7f57ac064bcd806d37. If the user cancels the
run cmake dialog, no buildconfiguration is created. The adding of kit
should then not happen. A target without a buildconfiguration should
not happen.
Task-number: QTCREATORBUG-12773
Change-Id: Ic43c5cc13f9e114ea24cc97154a6c084125f6318
Reviewed-by: Christian Stenger <christian.stenger@digia.com>
-rw-r--r-- | src/plugins/cmakeprojectmanager/cmakeproject.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/cmakeprojectmanager/cmakeproject.cpp b/src/plugins/cmakeprojectmanager/cmakeproject.cpp index 5a96b62270..6ae4e4e5f1 100644 --- a/src/plugins/cmakeprojectmanager/cmakeproject.cpp +++ b/src/plugins/cmakeprojectmanager/cmakeproject.cpp @@ -604,6 +604,8 @@ bool CMakeProject::fromMap(const QVariantMap &map) bool CMakeProject::setupTarget(Target *t) { t->updateDefaultBuildConfigurations(); + if (t->buildConfigurations().isEmpty()) + return false; t->updateDefaultDeployConfigurations(); return true; |