[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1358912351-14835-1-git-send-email-amwang@redhat.com>
Date: Wed, 23 Jan 2013 11:39:11 +0800
From: Cong Wang <amwang@...hat.com>
To: netdev@...r.kernel.org
Cc: "David S. Miller" <davem@...emloft.net>,
Cong Wang <amwang@...hat.com>
Subject: [Patch net-next] netpoll: fix an uninitialized variable
From: Cong Wang <amwang@...hat.com>
Fengguang reported:
net/core/netpoll.c: In function 'netpoll_setup':
net/core/netpoll.c:1049:6: warning: 'err' may be used uninitialized in this function [-Wmaybe-uninitialized]
in !CONFIG_IPV6 case, we may error out without initializing
'err'.
Reported-by: Fengguang Wu <fengguang.wu@...el.com>
Cc: David S. Miller <davem@...emloft.net>
Signed-off-by: Cong Wang <amwang@...hat.com>
---
diff --git a/net/core/netpoll.c b/net/core/netpoll.c
index a9b1004..e2f79a1 100644
--- a/net/core/netpoll.c
+++ b/net/core/netpoll.c
@@ -1140,6 +1140,7 @@ int netpoll_setup(struct netpoll *np)
#else
np_err(np, "IPv6 is not supported %s, aborting\n",
np->dev_name);
+ err = -EINVAL;
goto put;
#endif
}
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists