Summary: | gdb looks for "target:" file on the target | ||
---|---|---|---|
Product: | gdb | Reporter: | Tom Tromey <tromey> |
Component: | remote | Assignee: | Tom Tromey <tromey> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | P2 | ||
Version: | HEAD | ||
Target Milestone: | 14.1 | ||
Host: | Target: | ||
Build: | Last reconfirmed: |
Description
Tom Tromey
2022-12-21 20:48:56 UTC
The master branch has been updated by Tom Tromey <tromey@sourceware.org>: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=dacf80765d51be840d2efc20bc058643d88ec49f commit dacf80765d51be840d2efc20bc058643d88ec49f Author: Tom Tromey <tromey@adacore.com> Date: Wed Dec 21 13:57:45 2022 -0700 Remove target: prefix from gdb_sysroot in find_separate_debug_file I noticed that, when using gdbserver, gdb might print: Reading /usr/lib/debug/lib64//libcap.so.2.48-2.48-4.fc36.x86_64.debug from remote target... Reading target:/usr/lib/debug/lib64//libcap.so.2.48-2.48-4.fc36.x86_64.debug from remote target... The second line has the "target:" prefix, but from the code it's clear that this string is being passed verbatim to gdbserver -- which seems wrong. I filed PR remote/29929 for this. The problem here is that find_separate_debug_file uses gdb_sysroot without checking to see if it starts with the "target:" prefix. This patch changes this code to be a little more careful. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=29929 Fixed. |