Remove hardcoded line number from the zeroize test
Instead, we insert a comment containing GDB_BREAK_HERE in the line we want to break at, and let the gdb script search for it. Signed-off-by: Bence Szépkúti <bence.szepkuti@arm.com>
This commit is contained in:
parent
74fc3be396
commit
cd6fd060ec
2 changed files with 8 additions and 16 deletions
|
@ -31,19 +31,13 @@
|
|||
# the compiler potentially has a bug.
|
||||
#
|
||||
# Note: This test requires that the test program is compiled with -g3.
|
||||
#
|
||||
# WARNING: There does not seem to be a mechanism in GDB scripts to set a
|
||||
# breakpoint at the end of a function (probably because there are a lot of
|
||||
# complications as function can have multiple exit points, etc). Therefore, it
|
||||
# was necessary to hard-code the line number of the breakpoint in the zeroize.c
|
||||
# test app. The assumption is that zeroize.c is a simple test app that does not
|
||||
# change often (as opposed to the actual library code), so the breakpoint line
|
||||
# number does not need to be updated often.
|
||||
|
||||
set confirm off
|
||||
|
||||
file ./programs/test/zeroize
|
||||
break zeroize.c:100
|
||||
|
||||
search GDB_BREAK_HERE
|
||||
break $_
|
||||
|
||||
set args ./programs/test/zeroize.c
|
||||
run
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue