From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12364 invoked by alias); 28 Aug 2014 15:35:50 -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 12352 invoked by uid 89); 28 Aug 2014 15:35:50 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Thu, 28 Aug 2014 15:35:49 +0000 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s7SFZm41018057 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Thu, 28 Aug 2014 11:35:48 -0400 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.ams2.redhat.com [10.39.146.11]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s7SFZkeV015554; Thu, 28 Aug 2014 11:35:47 -0400 Message-ID: <53FF4C52.5000701@redhat.com> Date: Thu, 28 Aug 2014 15:35:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.7.0 MIME-Version: 1.0 To: Gary Benson , gdb-patches@sourceware.org Subject: Re: [PATCH 5/5] Use exceptions and cleanups in gdbserver References: <1408351618-21013-1-git-send-email-gbenson@redhat.com> <1408351618-21013-6-git-send-email-gbenson@redhat.com> In-Reply-To: <1408351618-21013-6-git-send-email-gbenson@redhat.com> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-SW-Source: 2014-08/txt/msg00618.txt.bz2 On 08/18/2014 09:46 AM, Gary Benson wrote: > diff --git a/gdb/gdbserver/server.h b/gdb/gdbserver/server.h > index 97498a6..cac73e9 100644 > diff --git a/gdb/gdbserver/utils.c b/gdb/gdbserver/utils.c > index 6283877..e2eb4f4 100644 > --- a/gdb/gdbserver/utils.c > +++ b/gdb/gdbserver/utils.c > @@ -17,6 +17,7 @@ > along with this program. If not, see . */ > > #include "server.h" > +#include "common-exceptions.h" > ... > diff --git a/gdb/gdbserver/server.c b/gdb/gdbserver/server.c > index 500260c..aec70f0 100644 > --- a/gdb/gdbserver/server.c > +++ b/gdb/gdbserver/server.c > @@ -35,6 +35,8 @@ > #include "tracepoint.h" > #include "dll.h" > #include "hostio.h" > +#include "common-exceptions.h" > +#include "cleanups.h" We'll want to start using exceptions/cleanups everywhere. We'll no doubt end up including them from a central place, either server.h or somewhere in common/. I think we should just put them in server.h already ... > --- a/gdb/gdbserver/server.h > +++ b/gdb/gdbserver/server.h > @@ -29,8 +29,6 @@ gdb_static_assert (sizeof (CORE_ADDR) >= sizeof (void *)); > > #include "version.h" > > -#include > - > #ifdef HAVE_ALLOCA_H > #include > #endif > @@ -88,8 +86,6 @@ extern int pass_signals[]; > extern int program_signals[]; > extern int program_signals_p; > > -extern jmp_buf toplevel; > - > extern int disable_packet_vCont; > extern int disable_packet_Tthread; > extern int disable_packet_qC; ... which is the same place we had the bare bones setjmp stuff, avoiding the sprinkling-includes-around-only-to-inevitably-remove-them-later. This way, even if we move them somewhere in common/ at some point, we'll still have only a single place to touch. Other than that, looks good. Thanks, Pedro Alves