public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches•com>
To: Ian Morris <ipm@chirality•org.uk>
Cc: netdev@vger•kernel.org
Subject: Re: [PATCH net-next 3/6] ipv6: netfilter: remove unnecessary braces
Date: Sat, 25 Apr 2015 08:59:02 -0700	[thread overview]
Message-ID: <1429977542.32250.12.camel@perches.com> (raw)
In-Reply-To: <1429954020-11763-4-git-send-email-ipm@chirality.org.uk>

On Sat, 2015-04-25 at 10:26 +0100, Ian Morris wrote:
> Remove braces from a few if statements where not required.

trivia:

> diff --git a/net/ipv6/netfilter/ip6_tables.c b/net/ipv6/netfilter/ip6_tables.c
[]
> @@ -151,9 +151,8 @@ ip6_packet_match(const struct sk_buff *skb,
>  				ip6info->proto);
>  
>  		if (ip6info->proto == protohdr) {
> -			if (ip6info->invflags & IP6T_INV_PROTO) {
> +			if (ip6info->invflags & IP6T_INV_PROTO)
>  				return false;
> -			}
>  			return true;

maybe
			return (!(ip6info->invflags & IP6T_INV_PROTO));

  reply	other threads:[~2015-04-25 15:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-25  9:26 [PATCH net-next 0/6] ipv6: netfilter - coding style improvements Ian Morris
2015-04-25  9:26 ` [PATCH net-next 1/6] ipv6: netfilter: Tidy up indenting Ian Morris
2015-04-25  9:26 ` [PATCH net-next 2/6] ipv6: netfilter: whitespace in line layouts Ian Morris
2015-04-25 15:57   ` Joe Perches
2015-04-25  9:26 ` [PATCH net-next 3/6] ipv6: netfilter: remove unnecessary braces Ian Morris
2015-04-25 15:59   ` Joe Perches [this message]
2015-04-25 16:54     ` Sergei Shtylyov
2015-04-25 17:01       ` Joe Perches
2015-04-25  9:26 ` [PATCH net-next 4/6] ipv6: netfilter: comparison for equality with NULL Ian Morris
2015-04-25  9:26 ` [PATCH net-next 5/6] ipv6: netfilter: comparison for inequality " Ian Morris
2015-04-25  9:27 ` [PATCH net-next 6/6] ipv6: netfilter: simply if-else statements Ian Morris
2015-04-25 16:17   ` Joe Perches
2015-04-27  2:43 ` [PATCH net-next 0/6] ipv6: netfilter - coding style improvements Pablo Neira Ayuso

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=1429977542.32250.12.camel@perches.com \
    --to=joe@perches$(echo .)com \
    --cc=ipm@chirality$(echo .)org.uk \
    --cc=netdev@vger$(echo .)kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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