From 0dc61f55c3919765ae0fd453de2719daeb4f0718 Mon Sep 17 00:00:00 2001 From: hjk Date: Tue, 14 Mar 2023 18:18:39 +0100 Subject: Debugger: Use more FilePath in source file handling Needed for the double-remote case. With this we have proper breakpoint markers in the text editor for a remotely running gdb on a remotely loaded project. Change-Id: If80e4a4108a4a0bcdd7612a59e2bd695213f5ea5 Reviewed-by: Orgad Shaneh --- src/plugins/debugger/breakpoint.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/plugins/debugger/breakpoint.cpp') diff --git a/src/plugins/debugger/breakpoint.cpp b/src/plugins/debugger/breakpoint.cpp index 8d456ef67f..79e2badf7b 100644 --- a/src/plugins/debugger/breakpoint.cpp +++ b/src/plugins/debugger/breakpoint.cpp @@ -265,7 +265,8 @@ static QString cleanupFullName(const QString &fileName) return cleanFilePath; } -void BreakpointParameters::updateFromGdbOutput(const GdbMi &bkpt) + +void BreakpointParameters::updateFromGdbOutput(const GdbMi &bkpt, const Utils::FilePath &fileRoot) { QTC_ASSERT(bkpt.isValid(), return); @@ -358,7 +359,7 @@ void BreakpointParameters::updateFromGdbOutput(const GdbMi &bkpt) QString name; if (!fullName.isEmpty()) { name = cleanupFullName(fullName); - fileName = Utils::FilePath::fromString(name); + fileName = fileRoot.withNewPath(name); //if (data->markerFileName().isEmpty()) // data->setMarkerFileName(name); } else { @@ -367,7 +368,7 @@ void BreakpointParameters::updateFromGdbOutput(const GdbMi &bkpt) // gdb's own. No point in assigning markerFileName for now. } if (!name.isEmpty()) - fileName = Utils::FilePath::fromString(name); + fileName = fileRoot.withNewPath(name); if (fileName.isEmpty()) updateLocation(originalLocation); -- cgit v1.2.1