Commit 2ec0bc9f authored by Oswald Buddenhagen's avatar Oswald Buddenhagen
Browse files

remove useless code

--tty + outputcollector, working dir and environment setup make sense
only for living local debuggees.
parent 6d18970b
......@@ -78,18 +78,6 @@ void AttachGdbAdapter::startAdapter()
gdbArgs.prepend(_("mi"));
gdbArgs.prepend(_("-i"));
if (!m_engine->m_outputCollector.listen()) {
emit adapterStartFailed(tr("Cannot set up communication with child process: %1")
.arg(m_engine->m_outputCollector.errorString()), QString());
return;
}
gdbArgs.prepend(_("--tty=") + m_engine->m_outputCollector.serverName());
if (!startParameters().workingDir.isEmpty())
setWorkingDirectory(startParameters().workingDir);
if (!startParameters().environment.isEmpty())
setEnvironment(startParameters().environment);
QString location = theDebuggerStringSetting(GdbLocation);
m_gdbProc.start(location, gdbArgs);
}
......
......@@ -78,18 +78,6 @@ void CoreGdbAdapter::startAdapter()
gdbArgs.prepend(_("mi"));
gdbArgs.prepend(_("-i"));
if (!m_engine->m_outputCollector.listen()) {
emit adapterStartFailed(tr("Cannot set up communication with child process: %1")
.arg(m_engine->m_outputCollector.errorString()), QString());
return;
}
gdbArgs.prepend(_("--tty=") + m_engine->m_outputCollector.serverName());
if (!startParameters().workingDir.isEmpty())
setWorkingDirectory(startParameters().workingDir);
if (!startParameters().environment.isEmpty())
setEnvironment(startParameters().environment);
QString location = theDebuggerStringSetting(GdbLocation);
m_gdbProc.start(location, gdbArgs);
}
......
......@@ -86,18 +86,6 @@ void RemoteGdbAdapter::startAdapter()
gdbArgs.prepend(_("mi"));
gdbArgs.prepend(_("-i"));
// if (!m_engine->m_outputCollector.listen()) {
// emit adapterStartFailed(tr("Cannot set up communication with child process: %1")
// .arg(m_engine->m_outputCollector.errorString()));
// return;
// }
// gdbArgs.prepend(_("--tty=") + m_engine->m_outputCollector.serverName());
if (!startParameters().workingDir.isEmpty())
setWorkingDirectory(startParameters().workingDir);
if (!startParameters().environment.isEmpty())
setEnvironment(startParameters().environment);
QString location = theDebuggerStringSetting(GdbLocation);
// FIXME: make asynchroneous
......@@ -106,10 +94,6 @@ void RemoteGdbAdapter::startAdapter()
m_engine->showStatusMessage(_("No server start script given. "
"Assuming server runs already."));
} else {
if (!startParameters().workingDir.isEmpty())
m_uploadProc.setWorkingDirectory(startParameters().workingDir);
if (!startParameters().environment.isEmpty())
m_uploadProc.setEnvironment(startParameters().environment);
m_uploadProc.start(_("/bin/sh ") + startParameters().serverStartScript);
m_uploadProc.waitForStarted();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment