提交 3324d024 编写于 作者: J Jiri Pirko 提交者: David S. Miller

team: init error value to 0 in team_netpoll_setup()

This will ensure correct value is returned in case the port list is empty.
Signed-off-by: NJiri Pirko <jiri@resnulli.us>
Reported-by: NEric Dumazet <edumazet@google.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 9cb429d6
......@@ -1447,7 +1447,7 @@ static int team_netpoll_setup(struct net_device *dev,
{
struct team *team = netdev_priv(dev);
struct team_port *port;
int err;
int err = 0;
mutex_lock(&team->lock);
list_for_each_entry(port, &team->port_list, list) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册