Skip to content

Commit

Permalink
bridge: remove unnecessary condition judgment
Browse files Browse the repository at this point in the history
Because err is always negative, remove unnecessary condition
judgment.

Signed-off-by: Tan Xiaojun <tanxiaojun@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
tanxiaojun authored and David S. Miller committed Dec 20, 2013
1 parent 5495ab7 commit 87e823b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
3 changes: 1 addition & 2 deletions net/bridge/br_fdb.c
Original file line number Diff line number Diff line change
Expand Up @@ -570,8 +570,7 @@ static void fdb_notify(struct net_bridge *br,
rtnl_notify(skb, net, 0, RTNLGRP_NEIGH, NULL, GFP_ATOMIC);
return;
errout:
if (err < 0)
rtnl_set_sk_err(net, RTNLGRP_NEIGH, err);
rtnl_set_sk_err(net, RTNLGRP_NEIGH, err);
}

/* Dump information about entries, in response to GETNEIGH */
Expand Down
3 changes: 1 addition & 2 deletions net/bridge/br_netlink.c
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,7 @@ void br_ifinfo_notify(int event, struct net_bridge_port *port)
rtnl_notify(skb, net, 0, RTNLGRP_LINK, NULL, GFP_ATOMIC);
return;
errout:
if (err < 0)
rtnl_set_sk_err(net, RTNLGRP_LINK, err);
rtnl_set_sk_err(net, RTNLGRP_LINK, err);
}


Expand Down

0 comments on commit 87e823b

Please sign in to comment.