From: Wang Yufen Date: Mon, 17 Feb 2014 08:53:35 +0000 (+0800) Subject: ipv6:fix checkpatch errors with assignment in if condition X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=cb6e926e3f734f0934d3cb5cd7c827158183d367;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git ipv6:fix checkpatch errors with assignment in if condition Signed-off-by: Wang Yufen Signed-off-by: David S. Miller --- diff --git a/net/ipv6/addrlabel.c b/net/ipv6/addrlabel.c index d7024066bddd..731e1e1722d9 100644 --- a/net/ipv6/addrlabel.c +++ b/net/ipv6/addrlabel.c @@ -504,12 +504,13 @@ static int ip6addrlbl_dump(struct sk_buff *skb, struct netlink_callback *cb) hlist_for_each_entry_rcu(p, &ip6addrlbl_table.head, list) { if (idx >= s_idx && net_eq(ip6addrlbl_net(p), net)) { - if ((err = ip6addrlbl_fill(skb, p, - ip6addrlbl_table.seq, - NETLINK_CB(cb->skb).portid, - cb->nlh->nlmsg_seq, - RTM_NEWADDRLABEL, - NLM_F_MULTI)) <= 0) + err = ip6addrlbl_fill(skb, p, + ip6addrlbl_table.seq, + NETLINK_CB(cb->skb).portid, + cb->nlh->nlmsg_seq, + RTM_NEWADDRLABEL, + NLM_F_MULTI); + if (err <= 0) break; } idx++; @@ -567,7 +568,8 @@ static int ip6addrlbl_get(struct sk_buff *in_skb, struct nlmsghdr *nlh) goto out; } - if (!(skb = nlmsg_new(ip6addrlbl_msgsize(), GFP_KERNEL))) { + skb = nlmsg_new(ip6addrlbl_msgsize(), GFP_KERNEL); + if (!skb) { ip6addrlbl_put(p); return -ENOBUFS; }