From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27590 invoked by alias); 14 Jul 2014 16:13:12 -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 27568 invoked by uid 89); 14 Jul 2014 16:13:11 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.7 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.3.2 X-HELO: rock.gnat.com Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-SHA encrypted) ESMTPS; Mon, 14 Jul 2014 16:13:09 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id E2E951161C0; Mon, 14 Jul 2014 12:13:07 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 0nsIFC9pc061; Mon, 14 Jul 2014 12:13:07 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id ADB6A116117; Mon, 14 Jul 2014 12:13:07 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id 03F3540EBF; Mon, 14 Jul 2014 09:13:09 -0700 (PDT) Date: Mon, 14 Jul 2014 16:13:00 -0000 From: Joel Brobecker To: Edjunior Barbosa Machado Cc: gdb-patches@sourceware.org, uweigand@de.ibm.com Subject: Re: [PATCH] Report "No hardware breakpoint support" correctly Message-ID: <20140714161308.GC4888@adacore.com> References: <1405349255-26782-1-git-send-email-emachado@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1405349255-26782-1-git-send-email-emachado@linux.vnet.ibm.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-SW-Source: 2014-07/txt/msg00341.txt.bz2 > gdb/ > 2014-07-14 Edjunior Barbosa Machado > > * gdb/ppc-linux-nat.c (ppc_linux_can_use_hw_breakpoint): Report no > hardware breakpoint support correctly. Just one itty bitty tiny little nit: > --- > gdb/ppc-linux-nat.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/gdb/ppc-linux-nat.c b/gdb/ppc-linux-nat.c > index fcfd452..4c5d878 100644 > --- a/gdb/ppc-linux-nat.c > +++ b/gdb/ppc-linux-nat.c > @@ -1473,6 +1473,9 @@ ppc_linux_can_use_hw_breakpoint (struct target_ops *self, > } > else if (type == bp_hardware_breakpoint) > { > + if (total_hw_bp == 0) > + /* No hardware breakpoint support. */ > + return 0; Can you nest the contents of the if block inside curly braces. We've decided a while ago that a comment looks visually like a statement, and thus that comment + statement looks the same as 2 statements, and thus normally requires curly braces... Thanks! -- Joel