Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1611708

[PATCH] net: ipv6: Removed unnecessary parenthesis

From Arushi Singhal <arushisinghal19971997@gmail.com>
Newsgroups linux.kernel
Subject [PATCH] net: ipv6: Removed unnecessary parenthesis
Date 2017-03-29 11:10 +0200
Message-ID <tqhM5-4Lj-3@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


Removed parentheses on the right hand side of assignment, as they are
not required. The following coccinelle script was used to fix this
issue:

@@
local idexpression id;
expression e;
@@

id =
-(
e
-)

Signed-off-by: Arushi Singhal <arushisinghal19971997@gmail.com>
---
 net/ipv6/netfilter/nf_conntrack_reasm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/net/ipv6/netfilter/nf_conntrack_reasm.c b/net/ipv6/netfilter/nf_conntrack_reasm.c
index fdde76e8a16a..34dfdc2fb2bc 100644
--- a/net/ipv6/netfilter/nf_conntrack_reasm.c
+++ b/net/ipv6/netfilter/nf_conntrack_reasm.c
@@ -387,9 +387,9 @@ nf_ct_frag6_reasm(struct frag_queue *fq, struct sk_buff *prev,  struct net_devic
 		return false;
 
 	/* Unfragmented part is taken from the first segment. */
-	payload_len = ((head->data - skb_network_header(head)) -
+	payload_len = (head->data - skb_network_header(head)) -
 		       sizeof(struct ipv6hdr) + fq->q.len -
-		       sizeof(struct frag_hdr));
+		       sizeof(struct frag_hdr);
 	if (payload_len > IPV6_MAXPLEN) {
 		net_dbg_ratelimited("nf_ct_frag6_reasm: payload len = %d\n",
 				    payload_len);
-- 
2.11.0

Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

[PATCH] net: ipv6: Removed unnecessary parenthesis Arushi Singhal <arushisinghal19971997@gmail.com> - 2017-03-29 11:10 +0200
  Re: [PATCH] net: ipv6: Removed unnecessary parenthesis Pablo Neira Ayuso <pablo@netfilter.org> - 2017-04-07 18:40 +0200

csiph-web