overhaul process argument handling

get away from argument stringlists. instead, use native shell command
lines which support quoting/splitting, environment variable expansion
and redirections with well-understood semantics.

Task-number: QTCREATORBUG-542
Task-number: QTCREATORBUG-1564
This commit is contained in:
Oswald Buddenhagen
2010-10-19 11:14:03 +02:00
parent 531c70f05b
commit 1e362b0f8b
91 changed files with 592 additions and 572 deletions

View File

@@ -46,6 +46,7 @@
#endif
#include <utils/qtcassert.h>
#include <utils/qtcprocess.h>
#include <utils/savedaction.h>
#include <QtCore/QTimer>
@@ -1551,10 +1552,11 @@ void TrkGdbAdapter::startAdapter()
m_symbolFile = parameters.symbolFileName;
QString remoteChannel = parameters.remoteChannel;
// FIXME: testing hack, remove!
if (parameters.processArgs.size() >= 4 && parameters.processArgs.at(0) == _("@sym@")) {
remoteChannel = parameters.processArgs.at(1);
m_remoteExecutable = parameters.processArgs.at(2);
m_symbolFile = parameters.processArgs.at(3);
if (m_remoteArguments.startsWith(__("@sym@ "))) {
QStringList pa = Utils::QtcProcess::splitArgs(m_remoteArguments);
remoteChannel = pa.at(1);
m_remoteExecutable = pa.at(2);
m_symbolFile = pa.at(3);
m_remoteArguments.clear();
}
// Unixish gdbs accept only forward slashes