summaryrefslogtreecommitdiff
path: root/src/plugins/debugger/gdb/gdbengine.cpp
diff options
context:
space:
mode:
authorhjk <hjk@qt.io>2023-03-14 17:47:33 +0100
committerhjk <hjk@qt.io>2023-03-15 11:36:16 +0000
commite813dff31c413c37a692150daa846381e09b09a4 (patch)
tree1701d44141c67356e21c99c6fc6baf36d8504dd4 /src/plugins/debugger/gdb/gdbengine.cpp
parent17100d4ca97893affe1ceff5782db52e3f67d518 (diff)
downloadqt-creator-e813dff31c413c37a692150daa846381e09b09a4.tar.gz
Debugger: Fix several uses of remote paths
... when passing into gdb. Change-Id: I8de8386fb1d398783dfa00ed883b1e44f0b2594a Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Orgad Shaneh <orgads@gmail.com>
Diffstat (limited to 'src/plugins/debugger/gdb/gdbengine.cpp')
-rw-r--r--src/plugins/debugger/gdb/gdbengine.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/plugins/debugger/gdb/gdbengine.cpp b/src/plugins/debugger/gdb/gdbengine.cpp
index b8ba1441ed..9f8dbac661 100644
--- a/src/plugins/debugger/gdb/gdbengine.cpp
+++ b/src/plugins/debugger/gdb/gdbengine.cpp
@@ -3947,10 +3947,10 @@ void GdbEngine::handleGdbStarted()
}
if (!rp.sysRoot.isEmpty()) {
- runCommand({"set sysroot " + rp.sysRoot.toString()});
+ runCommand({"set sysroot " + rp.sysRoot.path()});
// sysroot is not enough to correctly locate the sources, so explicitly
// relocate the most likely place for the debug source
- runCommand({"set substitute-path /usr/src " + rp.sysRoot.toString() + "/usr/src"});
+ runCommand({"set substitute-path /usr/src " + rp.sysRoot.path() + "/usr/src"});
}
//QByteArray ba = QFileInfo(sp.dumperLibrary).path().toLocal8Bit();
@@ -4145,7 +4145,7 @@ void GdbEngine::handleDebugInfoLocation(const DebuggerResponse &response)
const FilePath debugInfoLocation = runParameters().debugInfoLocation;
if (!debugInfoLocation.isEmpty() && debugInfoLocation.exists()) {
const QString curDebugInfoLocations = response.consoleStreamOutput.split('"').value(1);
- QString cmd = "set debug-file-directory " + debugInfoLocation.toString();
+ QString cmd = "set debug-file-directory " + debugInfoLocation.path();
if (!curDebugInfoLocations.isEmpty())
cmd += HostOsInfo::pathListSeparator() + curDebugInfoLocations;
runCommand({cmd});
@@ -4805,7 +4805,7 @@ void GdbEngine::handleTargetExtendedRemote(const DebuggerResponse &response)
runCommand({"attach " + QString::number(runParameters().attachPID.pid()),
CB(handleTargetExtendedAttach)});
} else if (!runParameters().inferior.command.isEmpty()) {
- runCommand({"-gdb-set remote exec-file " + runParameters().inferior.command.executable().toString(),
+ runCommand({"-gdb-set remote exec-file " + runParameters().inferior.command.executable().path(),
CB(handleTargetExtendedAttach)});
} else {
const QString title = Tr::tr("No Remote Executable or Process ID Specified");
@@ -4855,7 +4855,7 @@ void GdbEngine::handleTargetQnx(const DebuggerResponse &response)
if (rp.attachPID.isValid())
runCommand({"attach " + QString::number(rp.attachPID.pid()), CB(handleRemoteAttach)});
else if (!rp.inferior.command.isEmpty())
- runCommand({"set nto-executable " + rp.inferior.command.executable().toString(),
+ runCommand({"set nto-executable " + rp.inferior.command.executable().path(),
CB(handleSetNtoExecutable)});
else
handleInferiorPrepared();