Files
Andrew Burgess ce068c5f45 gdb: don't print global thread-id to CLI in describe_other_breakpoints
I noticed that describe_other_breakpoints was printing the global
thread-id to the CLI.  For CLI output we should be printing the
inferior local thread-id (e.g. "2.1").  This can be seen in the
following GDB session:

  (gdb) info threads
    Id   Target Id                                Frame
    1.1  Thread 4065742.4065742 "bp-thread-speci" main () at /tmp/bp-thread-specific.c:27
  * 2.1  Thread 4065743.4065743 "bp-thread-speci" main () at /tmp/bp-thread-specific.c:27
  (gdb) break foo thread 2.1
  Breakpoint 3 at 0x40110a: foo. (2 locations)
  (gdb) break foo thread 1.1
  Note: breakpoint 3 (thread 2) also set at pc 0x40110a.
  Note: breakpoint 3 (thread 2) also set at pc 0x40110a.
  Breakpoint 4 at 0x40110a: foo. (2 locations)

Notice that GDB says:

  Note: breakpoint 3 (thread 2) also set at pc 0x40110a.

The 'thread 2' in here is using the global thread-id, we should
instead say 'thread 2.1' which corresponds to how the user specified
the breakpoint.

This commit fixes this issue and adds a test.

Approved-By: Pedro Alves <pedro@palves.net>
2023-02-11 17:35:14 +00:00
..
2023-01-13 13:18:56 -07:00
2023-01-13 13:18:56 -07:00
2023-01-13 13:18:56 -07:00
2023-01-13 13:18:56 -07:00
2023-01-13 13:18:56 -07:00
2023-01-13 13:18:58 -07:00