All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next] ipv6: fix warning in xfrm6_mode_tunnel_input
@ 2013-02-16 17:38 Stephen Hemminger
  2013-02-16 17:40 ` [PATCH net-next] ip: fix warning in xfrm4_mode_tunnel_input Stephen Hemminger
  2013-02-18 17:43 ` [PATCH net-next] ipv6: fix warning in xfrm6_mode_tunnel_input David Miller
  0 siblings, 2 replies; 4+ messages in thread
From: Stephen Hemminger @ 2013-02-16 17:38 UTC (permalink / raw)
  To: Pravin B Shelar, David S. Miller; +Cc: netdev

Should not use assignment in conditional:
 warning: suggest parentheses around assignment used as truth value [-Wparentheses]

Problem introduced by:
commit 14bbd6a565e1bcdc240d44687edb93f721cfdf99
Author: Pravin B Shelar <pshelar@nicira.com>
Date:   Thu Feb 14 09:44:49 2013 +0000

    net: Add skb_unclone() helper function.
    

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>


--- a/net/ipv6/xfrm6_mode_tunnel.c	2013-02-16 09:09:41.388937316 -0800
+++ b/net/ipv6/xfrm6_mode_tunnel.c	2013-02-16 09:33:49.906203566 -0800
@@ -69,7 +69,8 @@ static int xfrm6_mode_tunnel_input(struc
 	if (!pskb_may_pull(skb, sizeof(struct ipv6hdr)))
 		goto out;
 
-	if (err = skb_unclone(skb, GFP_ATOMIC))
+	err = skb_unclone(skb, GFP_ATOMIC);
+	if (err)
 		goto out;
 
 	if (x->props.flags & XFRM_STATE_DECAP_DSCP)

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2013-02-18 17:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-16 17:38 [PATCH net-next] ipv6: fix warning in xfrm6_mode_tunnel_input Stephen Hemminger
2013-02-16 17:40 ` [PATCH net-next] ip: fix warning in xfrm4_mode_tunnel_input Stephen Hemminger
2013-02-18 17:43   ` David Miller
2013-02-18 17:43 ` [PATCH net-next] ipv6: fix warning in xfrm6_mode_tunnel_input David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.