netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: zhongjiang@huawei.com
Cc: stephen@networkplumber.org, netdev@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] net/bridge/br_multicast: remove redundant variable "err"
Date: Sun, 05 Aug 2018 17:33:36 -0700 (PDT)	[thread overview]
Message-ID: <20180805.173336.2098484669514510834.davem@davemloft.net> (raw)
In-Reply-To: <1533478723-18361-1-git-send-email-zhongjiang@huawei.com>

From: zhong jiang <zhongjiang@huawei.com>
Date: Sun, 5 Aug 2018 22:18:43 +0800

> @@ -1797,7 +1795,7 @@ static int br_multicast_ipv4_rcv(struct net_bridge *br,
>  	struct sk_buff *skb_trimmed = NULL;
>  	const unsigned char *src;
>  	struct igmphdr *ih;
> -	int err;
> +	int err = 0;
>  
>  	err = ip_mc_check_igmp(skb, &skb_trimmed);

The initialization of err to '0' is unnecessary, it gets assigned on
the very next line.

  parent reply	other threads:[~2018-08-06  0:33 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-05 14:18 [PATCH] net/bridge/br_multicast: remove redundant variable "err" zhong jiang
2018-08-06  0:18 ` Stephen Hemminger
2018-08-06  0:33 ` David Miller [this message]
2018-08-06  2:15   ` zhong jiang

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=20180805.173336.2098484669514510834.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.org \
    --cc=zhongjiang@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
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;
as well as URLs for NNTP newsgroup(s).