summaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
authorTakashi Kokubun <takashikkbn@gmail.com>2023-08-22 11:49:36 -0700
committerTakashi Kokubun <takashikkbn@gmail.com>2023-08-23 10:59:23 -0700
commit5766fb7266f3a9aaeb35acb2b374c684a5001b2a (patch)
tree14a3137316c3db9fe75e4fa269d2a81f7654dd73 /misc
parent9aca3528aa1a1545468a508b02b77bc922bb7321 (diff)
Fix gdb.py for C frames [ci skip]
Diffstat (limited to 'misc')
-rw-r--r--misc/gdb.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/misc/gdb.py b/misc/gdb.py
index 8f22bc91e1..6034a389bb 100644
--- a/misc/gdb.py
+++ b/misc/gdb.py
@@ -92,8 +92,9 @@ class CFP(gdb.Command):
self.print_env(cfp, -1, self.frame_types(cfp, -1))
print()
- # We can't calculate BP for the first frame
- if cfp_index > 0:
+ # We can't calculate BP for the first frame.
+ # vm_base_ptr doesn't work for C frames either.
+ if cfp_index > 0 and self.get_int(f'{cfp}->iseq'):
if args.stack_size is not None:
stack_size = args.stack_size
else: