From: Pedro Alves <palves@redhat.com>
To: Andrew Burgess <aburgess@broadcom.com>
Cc: gdb-patches@sourceware.org
Subject: Re: [PATCH 1/4] Remove deprecated_throw_reason from internal_verror.
Date: Tue, 30 Jul 2013 19:08:00 -0000 [thread overview]
Message-ID: <51F80F18.8070805@redhat.com> (raw)
In-Reply-To: <51F7E573.6040001@broadcom.com>
On 07/30/2013 05:10 PM, Andrew Burgess wrote:
> Removes the use of deprecated_throw_reason from internal_verror. The user
> will now get an extra "Command aborted" error message in the case where gdb
> hits an internal error, and the user decides not to quit. This feels like
> an improvement to me as it /might/ not be obvious that choosing to continue
> the session will still drop you out of whatever command you were attempting
> at the time. What do you think?
...
> diff --git a/gdb/utils.c b/gdb/utils.c
> index 01212ab..a4ce01c 100644
> --- a/gdb/utils.c
> +++ b/gdb/utils.c
> @@ -831,7 +831,7 @@ void
> internal_verror (const char *file, int line, const char *fmt, va_list ap)
> {
> internal_vproblem (&internal_error_problem, file, line, fmt, ap);
> - deprecated_throw_reason (RETURN_ERROR);
> + throw_error (GENERIC_ERROR, _("Command aborted"));
That error can still be swallowed by a TRY_CATCH somewhere, and the
command might proceed. I think we should throw a RETURN_QUIT instead,
which has exactly that semantic of cancelling the ongoing command.
IOW, I think this should call "fatal" instead.
--
Pedro Alves
next prev parent reply other threads:[~2013-07-30 19:08 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-30 16:09 [PATCH 0/4] Remove deprecated_throw_reason Andrew Burgess
2013-07-30 16:10 ` [PATCH 1/4] Remove deprecated_throw_reason from internal_verror Andrew Burgess
2013-07-30 19:08 ` Pedro Alves [this message]
2013-07-31 10:52 ` Andrew Burgess
2013-07-30 16:11 ` [PATCH 2/4] Remove deprecated_throw_reason from mips_error Andrew Burgess
2013-07-30 19:14 ` Pedro Alves
2013-07-31 12:37 ` Andrew Burgess
2013-07-31 14:44 ` Pedro Alves
2013-07-31 15:37 ` Andrew Burgess
2013-07-30 16:12 ` [PATCH 3/4] Remove remaining uses of deprecated_throw_reason Andrew Burgess
2013-07-30 19:21 ` Pedro Alves
2013-07-31 12:45 ` Andrew Burgess
2013-07-30 16:13 ` [PATCH 4/4] Remove deprecated_throw_reason Andrew Burgess
2013-07-30 19:22 ` Pedro Alves
2013-07-31 15:45 ` Andrew Burgess
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=51F80F18.8070805@redhat.com \
--to=palves@redhat.com \
--cc=aburgess@broadcom.com \
--cc=gdb-patches@sourceware.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox