aboutsummaryrefslogtreecommitdiff
path: root/gdb/python/py-newobjfileevent.c
diff options
context:
space:
mode:
authorHannes Domani <ssbssa@yahoo.de>2023-12-12 15:57:14 +0100
committerHannes Domani <ssbssa@yahoo.de>2023-12-12 15:57:14 +0100
commit80ffe7226459e3edf840d0c23462d93cb560d2de (patch)
tree558fb8d74b28d63aae0fca8744249931798e7a0d /gdb/python/py-newobjfileevent.c
parent52e0b52e6f2dc1dc5a7b95740d22fd616241db67 (diff)
downloadgdb-80ffe7226459e3edf840d0c23462d93cb560d2de.zip
gdb-80ffe7226459e3edf840d0c23462d93cb560d2de.tar.gz
gdb-80ffe7226459e3edf840d0c23462d93cb560d2de.tar.bz2
Fix gdb.FinishBreakpoint when returning to an inlined function
Currently, when creating a gdb.FinishBreakpoint in a function called from an inline frame, it will never be hit: ``` (gdb) py fb=gdb.FinishBreakpoint() Temporary breakpoint 1 at 0x13f1917b4: file C:/src/repos/binutils-gdb.git/gdb/testsuite/gdb.python/py-finish-breakpoint.c, line 47. (gdb) c Continuing. Thread-specific breakpoint 1 deleted - thread 1 no longer in the thread list. [Inferior 1 (process 1208) exited normally] ``` The reason is that the frame_id of a breakpoint has to be the ID of a real frame, ignoring any inline frames. With this fixed, it's working correctly: ``` (gdb) py fb=gdb.FinishBreakpoint() Temporary breakpoint 1 at 0x13f5617b4: file C:/src/repos/binutils-gdb.git/gdb/testsuite/gdb.python/py-finish-breakpoint.c, line 47. (gdb) c Continuing. Breakpoint 1, increase_inlined (a=0x40fa5c) at C:/src/repos/binutils-gdb.git/gdb/testsuite/gdb.python/py-finish-breakpoint.c:47 (gdb) py print(fb.return_value) -8 ``` Approved-By: Tom Tromey <tom@tromey.com>
Diffstat (limited to 'gdb/python/py-newobjfileevent.c')
0 files changed, 0 insertions, 0 deletions