From 17f44b5a8f68d1ff031aa597506c5f7995f445c4 Mon Sep 17 00:00:00 2001 From: Filipe Azevedo Date: Thu, 19 Oct 2017 11:23:03 +0200 Subject: [PATCH] Don't run controls that get no produced workers Change-Id: I9630620753f32934020d18266436472c869d9cd1 Reviewed-by: hjk --- src/plugins/projectexplorer/projectexplorer.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/plugins/projectexplorer/projectexplorer.cpp b/src/plugins/projectexplorer/projectexplorer.cpp index 1353f2dec5c..ce7c9d13fa8 100644 --- a/src/plugins/projectexplorer/projectexplorer.cpp +++ b/src/plugins/projectexplorer/projectexplorer.cpp @@ -2049,7 +2049,13 @@ void ProjectExplorerPluginPrivate::executeRunConfiguration(RunConfiguration *run QTC_ASSERT(producer, return); auto runControl = new RunControl(runConfiguration, runMode); - (void) producer(runControl); + + // A user needed interaction may have cancelled the run + // (by example asking for a process pid or server url). + if (!producer(runControl)) { + delete runControl; + return; + } emit m_instance->aboutToExecuteProject(runConfiguration->target()->project(), runMode);