aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/corelib/buildgraph/rulecommands.cpp
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@qt.io>2017-09-28 12:56:02 +0200
committerChristian Kandeler <christian.kandeler@qt.io>2017-09-29 08:59:30 +0000
commit83f43f57ac79fa673fda08805e29763a8303d5ea (patch)
treef8ad104c63abdbd38b006240ce348fe94737c778 /src/lib/corelib/buildgraph/rulecommands.cpp
parent76ca62e5968125b6674ff267544641f11726d9b9 (diff)
Lower the default response file threshold a bit on Windowsv1.9.1
It has been observed that values somewhat below 32000 can cause issues as well, so use a "safety offset". Task-number: QBS-1201 Change-Id: Ic82a4b4a9d770d8d92b955d1e70194de5baeae1b Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Diffstat (limited to 'src/lib/corelib/buildgraph/rulecommands.cpp')
-rw-r--r--src/lib/corelib/buildgraph/rulecommands.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/lib/corelib/buildgraph/rulecommands.cpp b/src/lib/corelib/buildgraph/rulecommands.cpp
index 6419d4e58..0044bdd5c 100644
--- a/src/lib/corelib/buildgraph/rulecommands.cpp
+++ b/src/lib/corelib/buildgraph/rulecommands.cpp
@@ -202,11 +202,19 @@ void ProcessCommand::setupForJavaScript(QScriptValue targetObject)
ProcessCommand::ProcessCommand()
: m_maxExitCode(0)
- , m_responseFileThreshold(HostOsInfo::isWindowsHost() ? 32000 : -1)
+ , m_responseFileThreshold(defaultResponseFileThreshold())
, m_responseFileArgumentIndex(0)
{
}
+int ProcessCommand::defaultResponseFileThreshold() const
+{
+ // TODO: Non-Windows platforms likely have their own limits. Investigate.
+ return HostOsInfo::isWindowsHost()
+ ? 31000 // 32000 minus "safety offset"
+ : -1;
+}
+
void ProcessCommand::getEnvironmentFromList(const QStringList &envList)
{
m_environment.clear();