(sig.sh:7):
7:	if [[ "$1"x != x ]] ; then
+# Test that debugged program's signals are saved and restored across
+# debug calls.
+### Testing that we have our signal set up...
+info signals
Signal       Stop   Print   Stack     Value
EXIT         stop   noprint nostack   trap -- '_Dbg_exit_handler "$BASH_COMMAND"' EXIT
EXIT         stop   noprint nostack   trap -- '_Dbg_exit_handler "$BASH_COMMAND"' EXIT
SIGINT       stop   print   showstack trap -- '_Dbg_sig_handler 2 "$BASH_COMMAND" "$@"' SIGINT
SIGQUIT      stop   print   showstack trap -- '_Dbg_sig_handler 3 "$BASH_COMMAND" "$@"' SIGQUIT
SIGILL       stop   print   showstack trap -- '_Dbg_sig_handler 4 "$BASH_COMMAND" "$@"' SIGILL
SIGTRAP      stop   print   showstack trap -- '_Dbg_sig_handler 5 "$BASH_COMMAND" "$@"' SIGTRAP
SIGTERM      stop   print   showstack trap -- '_Dbg_sig_handler 15 "$BASH_COMMAND" "$@"' SIGTERM
SIGXFSZ      nostop noprint nostack   trap -- '' SIGXFSZ
+### Testing handle command...
+handle TERM nostack
+handle foo
** Bad signal name: foo
+handle 1000
** Bad signal number: 1000
+handle TERM bogus
** Need to give a command: stop, nostop, stack, nostack, print, noprint
+eval kill -TERM $$
Program received signal SIGTERM (15)...
+### Should not have printed a stack trace above...
+handle TERM noprint
+handle TERM stack
+handle INT nostop
+info signals
Signal       Stop   Print   Stack     Value
EXIT         stop   noprint nostack   trap -- '_Dbg_exit_handler "$BASH_COMMAND"' EXIT
EXIT         stop   noprint nostack   trap -- '_Dbg_exit_handler "$BASH_COMMAND"' EXIT
SIGINT       nostop print   showstack trap -- '_Dbg_sig_handler 2 "$BASH_COMMAND" "$@"' SIGINT
SIGQUIT      stop   print   showstack trap -- '_Dbg_sig_handler 3 "$BASH_COMMAND" "$@"' SIGQUIT
SIGILL       stop   print   showstack trap -- '_Dbg_sig_handler 4 "$BASH_COMMAND" "$@"' SIGILL
SIGTRAP      stop   print   showstack trap -- '_Dbg_sig_handler 5 "$BASH_COMMAND" "$@"' SIGTRAP
SIGTERM      stop   noprint showstack trap -- '_Dbg_sig_handler 15 "$BASH_COMMAND" "$@"' SIGTERM
SIGXFSZ      nostop noprint nostack   trap -- '' SIGXFSZ
+quit
bashdb: That's all, folks...
