From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 23734 invoked by alias); 25 Jan 2016 22:14:15 -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 23722 invoked by uid 89); 25 Jan 2016 22:14:15 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=peculiar, voice, desire 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; Mon, 25 Jan 2016 22:14:14 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (Postfix) with ESMTPS id 2342EC0AC900; Mon, 25 Jan 2016 22:14:13 +0000 (UTC) Received: from blokker.wildebeest.org (ovpn-116-24.ams2.redhat.com [10.36.116.24]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id u0PMEBk8028728 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 25 Jan 2016 17:14:12 -0500 Received: by blokker.wildebeest.org (Postfix, from userid 1000) id 4E3ED200B0; Mon, 25 Jan 2016 23:14:11 +0100 (CET) Date: Mon, 25 Jan 2016 22:14:00 -0000 From: Mark Wielaard To: Simon Marchi Cc: gdb-patches@sourceware.org Subject: Re: [PATCH] Fix GCC6 -Wmisleading-indentation issues. Message-ID: <20160125221411.GA2721@blokker.redhat.com> References: <1453750851-29990-1-git-send-email-mjw@redhat.com> <56A697A2.9060207@ericsson.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <56A697A2.9060207@ericsson.com> User-Agent: Mutt/1.5.24 (2015-08-30) X-SW-Source: 2016-01/txt/msg00637.txt.bz2 On Mon, Jan 25, 2016 at 04:46:10PM -0500, Simon Marchi wrote: > If you feel like it, you could build with --enable-targets=all to > enable more code. > You'll find more of these. Thanks, but honestly this was just inspired by my desire to get a local build with gcc6 going. It would be good to build more code with GCC6 of course. I am sure it will find interesting issues. > One little comment below, otherwise it LGTM (without implying that my voice is > worth anything). > > > diff --git a/gdb/inflow.c b/gdb/inflow.c > > index bbd2b12..d1dd41c 100644 > > --- a/gdb/inflow.c > > +++ b/gdb/inflow.c > > @@ -413,7 +413,7 @@ child_terminal_ours_1 (int output_only) > > if (tinfo->run_terminal != NULL || gdb_has_a_terminal () == 0) > > return; > > > > - { > > + { > > #ifdef SIGTTOU > > /* Ignore this signal since it will happen when we try to set the > > pgrp. */ > > @@ -497,7 +497,7 @@ child_terminal_ours_1 (int output_only) > > result = fcntl (0, F_SETFL, our_terminal_info.tflags); > > result = fcntl (0, F_SETFL, our_terminal_info.tflags); > > #endif > > - } > > + } > > Shouldn't the code inside the brackets be de-indented too? Possibly. Or remove the whole block and move stuff into the outer scope now that it isn't strictly needed. But both create lots of code movement because of the peculiar ifdefs in this code. And it clearly wasn't the intention of the original author that removed the if statement in commit d9d2d8b. Thanks, Mark