summaryrefslogtreecommitdiff
path: root/src/lib/buildgraph
diff options
context:
space:
mode:
authorJake Petroules <jake.petroules@petroules.com>2013-09-03 15:47:19 -0400
committerJake Petroules <jake.petroules@petroules.com>2013-09-04 14:44:18 +0200
commit8269d5d54566685081b5e1b2cf2075460b8ff112 (patch)
treefe4ff80ad5968910eefa37ca39e651fcb714f7f4 /src/lib/buildgraph
parent9da9f9f91241deba28c0fc6b3d818b7f88848915 (diff)
downloadqbs-8269d5d54566685081b5e1b2cf2075460b8ff112.tar.gz
Fix incorrect logging output.
commandArgsToString will already always start with a space so the extra one was redundant and incorrect. empty string arguments are also quoted for clarity (these empty strings do get passed as actual arguments so this is good for debugging). Change-Id: Iba1c825a4ce62544b4df5e554c9453d2d2e22b10 Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
Diffstat (limited to 'src/lib/buildgraph')
-rw-r--r--src/lib/buildgraph/processcommandexecutor.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/buildgraph/processcommandexecutor.cpp b/src/lib/buildgraph/processcommandexecutor.cpp
index d123fe8f4..111ba4b64 100644
--- a/src/lib/buildgraph/processcommandexecutor.cpp
+++ b/src/lib/buildgraph/processcommandexecutor.cpp
@@ -80,7 +80,7 @@ static QString commandArgsToString(const QStringList &args)
foreach (const QString &arg, args) {
result += QLatin1Char(' ');
- if (arg.contains(ws))
+ if (arg.contains(ws) || arg.isEmpty())
result += QLatin1Char('"') + arg + QLatin1Char('"');
else
result += arg;
@@ -151,7 +151,7 @@ void ProcessCommandExecutor::doStart()
}
logger().qbsDebug() << "[EXEC] Running external process; full command line is: " << program
- << " " << commandArgsToString(arguments);
+ << commandArgsToString(arguments);
logger().qbsTrace() << "[EXEC] Additional environment:" << additionalVariables.toStringList();
m_process.setWorkingDirectory(cmd->workingDir());
m_process.start(program, arguments);