diff options
Diffstat (limited to 'net/ipv6/af_inet6.c')
-rw-r--r-- | net/ipv6/af_inet6.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv6/af_inet6.c b/net/ipv6/af_inet6.c index 21931c86e95b..e5c5aad44bb1 100644 --- a/net/ipv6/af_inet6.c +++ b/net/ipv6/af_inet6.c | |||
@@ -302,7 +302,7 @@ int inet6_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len) | |||
302 | err = -EINVAL; | 302 | err = -EINVAL; |
303 | goto out; | 303 | goto out; |
304 | } | 304 | } |
305 | dev = dev_get_by_index(sk->sk_bound_dev_if); | 305 | dev = dev_get_by_index(&init_net, sk->sk_bound_dev_if); |
306 | if (!dev) { | 306 | if (!dev) { |
307 | err = -ENODEV; | 307 | err = -ENODEV; |
308 | goto out; | 308 | goto out; |