This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFC/PATCH] New convenience variable $_exitsignal
- From: Eli Zaretskii <eliz at gnu dot org>
- To: Sergio Durigan Junior <sergiodj at redhat dot com>
- Cc: gdb-patches at sourceware dot org, palves at redhat dot com
- Date: Sun, 16 Jun 2013 19:21:09 +0300
- Subject: Re: [RFC/PATCH] New convenience variable $_exitsignal
- References: <m3mwqqvagk dot fsf at redhat dot com>
- Reply-to: Eli Zaretskii <eliz at gnu dot org>
> From: Sergio Durigan Junior <sergiodj@redhat.com>
> Cc: Pedro Alves <palves@redhat.com>
> Date: Sun, 16 Jun 2013 03:25:15 -0300
>
> This patch was proposed by Pedro at:
>
> <http://sourceware.org/ml/gdb-patches/2013-06/msg00337.html>
>
> It adds a new convenience variable called "$_exitsignal", which will
> hold the signal number when the inferior terminates due to the uncaught
> signal.
Thanks.
> diff --git a/gdb/NEWS b/gdb/NEWS
> index eea9917..e9e81b3 100644
> --- a/gdb/NEWS
> +++ b/gdb/NEWS
> @@ -69,6 +69,10 @@ show range-stepping
> * The exception-related catchpoints, like "catch throw", now accept a
> regular expression which can be used to filter exceptions by type.
>
> +* The new convenience variable $_exitsignal is automatically set to
> + the signal number when the program being debugged dies due to an
> + uncaught signal.
I'd say "set to the terminating signal number". Otherwise, OK.
> +@item $_exitsignal
> +@vindex $_exitsignal@r{, convenience variable}
> +The variable @code{$_exitsignal} is automatically set to the signal
> +number when the program being debugged dies due to an uncaught signal.
I'd reverse the order:
When the program being debugged dies due to an uncaught signal,
@value{GDBN} automatically sets this variable to that signal's
number.