Skip to content

Commit 2711d6b

Browse files
committed
Work around gdb bug in Ubuntu 20 LTS
1 parent 613b0c3 commit 2711d6b

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/test/watchpoint_unaligned.py

+5
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@ def test():
66
for type in ['uint16_t', 'uint32_t', 'uint64_t']:
77
send_gdb('c')
88
expect_gdb(f'Breakpoint {bp}')
9+
# Get the value of `wp_addr` from the parent frame.
10+
# On Ubuntu 20 LTS, gdb stops before the `breakpoint` prelude so
11+
# gets the wrong value of `wp_addr`.
12+
send_gdb('up')
13+
expect_gdb('test')
914
wp = set_watchpoint(f'-l *({type} *)wp_addr')
1015
send_gdb('c')
1116
expect_gdb(f'watchpoint {wp}')

0 commit comments

Comments
 (0)