forked from qt-creator/qt-creator
Debugger: Let the DebuggerRunTool optionally handle the PortsGatherer
Less code in the target implementations. Change-Id: I759f082eba5eab7f4e8252c0d7b5ec64059ba860 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -1988,15 +1988,12 @@ public:
|
||||
{
|
||||
IDevice::ConstPtr device = DeviceKitInformation::device(kit);
|
||||
setDisplayName("AttachToRunningProcess");
|
||||
setUsePortsGatherer(true, false);
|
||||
portsGatherer()->setDevice(device);
|
||||
|
||||
portsGatherer = new GdbServerPortsGatherer(runControl);
|
||||
portsGatherer->setUseGdbServer(true);
|
||||
portsGatherer->setUseQmlServer(false);
|
||||
portsGatherer->setDevice(device);
|
||||
|
||||
auto gdbServer = new GdbServerRunner(runControl, portsGatherer);
|
||||
auto gdbServer = new GdbServerRunner(runControl, portsGatherer());
|
||||
gdbServer->setUseMulti(false);
|
||||
gdbServer->addStartDependency(portsGatherer);
|
||||
gdbServer->addStartDependency(portsGatherer());
|
||||
gdbServer->setDevice(device);
|
||||
gdbServer->setAttachPid(ProcessHandle(pid));
|
||||
|
||||
@@ -2009,14 +2006,6 @@ public:
|
||||
setUseContinueInsteadOfRun(true);
|
||||
setContinueAfterAttach(false);
|
||||
}
|
||||
|
||||
void start() final
|
||||
{
|
||||
setRemoteChannel(portsGatherer->gdbServerChannel());
|
||||
DebuggerRunTool::start();
|
||||
}
|
||||
|
||||
GdbServerPortsGatherer *portsGatherer;
|
||||
};
|
||||
|
||||
void DebuggerPluginPrivate::attachToRunningApplication()
|
||||
|
||||
Reference in New Issue
Block a user