netdev
[Top] [All Lists]

[PATCH] - Fixes sparse warning in ipv6/ipv6_sockglue.c

To: akpm <akpm@xxxxxxxx>
Subject: [PATCH] - Fixes sparse warning in ipv6/ipv6_sockglue.c
From: Luiz Fernando Capitulino <lcapitulino@xxxxxxxxxxxxxxx>
Date: Mon, 14 Nov 2005 09:54:22 -0200
Cc: lkml <linux-kernel@xxxxxxxxxxxxxxx>, netdev@xxxxxxxxxxx
Organization: Mandriva
Sender: netdev-bounce@xxxxxxxxxxx
Hi,

The patch below fixes the following sparse warning:

net/ipv6/ipv6_sockglue.c:291:13: warning: Using plain integer as NULL pointer

Signed-off-by: Luiz Capitulino <lcapitulino@xxxxxxxxxxxxxxx>

 net/ipv6/ipv6_sockglue.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/ipv6/ipv6_sockglue.c b/net/ipv6/ipv6_sockglue.c
--- a/net/ipv6/ipv6_sockglue.c
+++ b/net/ipv6/ipv6_sockglue.c
@@ -287,7 +287,7 @@ int ipv6_setsockopt(struct sock *sk, int
        {
                struct ipv6_txoptions *opt;
                if (optlen == 0)
-                       optval = 0;
+                       optval = NULL;
 
                /* hop-by-hop / destination options are privileged option */
                retv = -EPERM;


-- 
Luiz Fernando N. Capitulino

<Prev in Thread] Current Thread [Next in Thread>