From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 14956 invoked by alias); 31 Jul 2013 10:52:49 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 14934 invoked by uid 89); 31 Jul 2013 10:52:49 -0000 X-Spam-SWARE-Status: No, score=-3.9 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_DNSWL_MED,RCVD_IN_HOSTKARMA_W,RDNS_NONE autolearn=ham version=3.3.1 Received: from Unknown (HELO mms2.broadcom.com) (216.31.210.18) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Wed, 31 Jul 2013 10:52:48 +0000 Received: from [10.9.208.55] by mms2.broadcom.com with ESMTP (Broadcom SMTP Relay (Email Firewall v6.5)); Wed, 31 Jul 2013 03:46:28 -0700 X-Server-Uuid: 4500596E-606A-40F9-852D-14843D8201B2 Received: from IRVEXCHSMTP2.corp.ad.broadcom.com (10.9.207.52) by IRVEXCHCAS07.corp.ad.broadcom.com (10.9.208.55) with Microsoft SMTP Server (TLS) id 14.1.438.0; Wed, 31 Jul 2013 03:52:32 -0700 Received: from mail-irva-13.broadcom.com (10.10.10.20) by IRVEXCHSMTP2.corp.ad.broadcom.com (10.9.207.52) with Microsoft SMTP Server id 14.1.438.0; Wed, 31 Jul 2013 03:52:32 -0700 Received: from [10.177.72.91] (unknown [10.177.72.91]) by mail-irva-13.broadcom.com (Postfix) with ESMTP id D57C6F2D74; Wed, 31 Jul 2013 03:52:31 -0700 (PDT) Message-ID: <51F8EC6F.7050100@broadcom.com> Date: Wed, 31 Jul 2013 10:52:00 -0000 From: "Andrew Burgess" User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:17.0) Gecko/20130620 Thunderbird/17.0.7 MIME-Version: 1.0 To: gdb-patches@sourceware.org cc: "Pedro Alves" Subject: Re: [PATCH 1/4] Remove deprecated_throw_reason from internal_verror. References: <51F7E51E.3070807@broadcom.com> <51F7E573.6040001@broadcom.com> <51F80F18.8070805@redhat.com> In-Reply-To: <51F80F18.8070805@redhat.com> Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 7bit X-SW-Source: 2013-07/txt/msg00813.txt.bz2 On 30/07/2013 8:08 PM, Pedro Alves wrote: > 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. Committed with a call to fatal. Thanks, Andrew