From 7d02a76be1888125b924f579ed2776ed80cc02fc Mon Sep 17 00:00:00 2001 From: hjk Date: Tue, 4 Jun 2019 11:05:32 +0200 Subject: [PATCH] PythonEditor: Use Utils::CommandLine when creating a runnable Change-Id: I670390f6034923d1f7f750435c0c8eb02d60b6f6 Reviewed-by: Christian Stenger --- src/plugins/pythoneditor/pythoneditorplugin.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/plugins/pythoneditor/pythoneditorplugin.cpp b/src/plugins/pythoneditor/pythoneditorplugin.cpp index 889880dc863..d07c68cd9a0 100644 --- a/src/plugins/pythoneditor/pythoneditorplugin.cpp +++ b/src/plugins/pythoneditor/pythoneditorplugin.cpp @@ -299,11 +299,12 @@ void PythonRunConfiguration::updateTargetInformation() Runnable PythonRunConfiguration::runnable() const { + CommandLine cmd{executable(), {}}; + cmd.addArg(mainScript()); + cmd.addArgs(aspect()->arguments(macroExpander())); + Runnable r; - QtcProcess::addArg(&r.commandLineArguments, mainScript()); - QtcProcess::addArgs(&r.commandLineArguments, - aspect()->arguments(macroExpander())); - r.executable = executable().toString(); + r.setCommandLine(cmd); r.environment = aspect()->environment(); return r; }