From 676d32680ce953572d713c9d4651b24fdffdcd85 Mon Sep 17 00:00:00 2001 From: short <> Date: Sat, 21 Jul 2001 01:50:51 +0000 Subject: [PATCH] Some useful general functions --- .gdbinit | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .gdbinit diff --git a/.gdbinit b/.gdbinit new file mode 100644 index 0000000..f60ba04 --- /dev/null +++ b/.gdbinit @@ -0,0 +1,36 @@ +set history filename /home/short/.gdb_history +set history save on +define rt + break $arg0 + run +# clear $arg0 + end +define ct + break $arg0 + continue + clear $arg0 + end +define rtl + break main + run + clear main + break $arg0 + continue +# clear $arg0 + end +define pglist3 + if (*("$arg1")=='@') + set var $arg1=struct $arg1 + set var $pglist_list=$arg0 + while ($pglist_list) + if (!strcmp("$arg2",".")) + print *(($arg1 *)$pglist_list->data) + else + print *(($arg1 *)$pglist_list->data)$arg2 + end + set var $pglist_list=$pglist_list->next + end + end +define pglist + pglist3 $arg0 $arg1 . + end -- 1.8.3.1