From 144c8fc5a4ac2740bc443f849e8ab762f9b4f78e Mon Sep 17 00:00:00 2001 From: johannst Date: Thu, 28 Nov 2019 20:00:42 +0100 Subject: added qualified breakpts + added workaround for command & finish bug --- gdb.txt | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) (limited to 'gdb.txt') diff --git a/gdb.txt b/gdb.txt index 033a3bf..f064cb5 100644 --- a/gdb.txt +++ b/gdb.txt @@ -34,8 +34,10 @@ load symbols of shared lib, if REGEX then only symbols for matching libs - break thread + break [-qualified] thread set a breakpoint only on a specific thread + -qualified: sym must be fully qualified (quiet handy + to set breakpoints on C symbols in C++ contexts) rbreak set breakpoints based on symbols matching regex is internally expanded to .*.* @@ -100,7 +102,7 @@ catch signal SIGSEGV command bt - ct + c end # quickly execute gdb command on running process, eg get backtrace from @@ -125,6 +127,19 @@ - cmd: $> gdb -p -x ./run.gdb --batch &> run.log + # workaround command + finish bug + # issue: when using finish in a command block, actions after finish will not + # be executed + - script: + define handler + bt + finish + info reg rax + end + + command + handler + end -------------------------------------------------------------------------------- vim:ft=help:sts=2:et:tw=80:cc=80:fo+=t -- cgit v1.2.3