aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/af_inet.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/ipv4/af_inet.c')
-rw-r--r--net/ipv4/af_inet.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/net/ipv4/af_inet.c b/net/ipv4/af_inet.c
index 06cfb0bed631..5882a1316441 100644
--- a/net/ipv4/af_inet.c
+++ b/net/ipv4/af_inet.c
@@ -464,7 +464,7 @@ int inet_bind(struct socket *sock, struct sockaddr *uaddr, int addr_len)
464 if (addr_len < sizeof(struct sockaddr_in)) 464 if (addr_len < sizeof(struct sockaddr_in))
465 goto out; 465 goto out;
466 466
467 chk_addr_ret = inet_addr_type(sk->sk_net, addr->sin_addr.s_addr); 467 chk_addr_ret = inet_addr_type(sock_net(sk), addr->sin_addr.s_addr);
468 468
469 /* Not specified by any standard per-se, however it breaks too 469 /* Not specified by any standard per-se, however it breaks too
470 * many applications when removed. It is unfortunate since 470 * many applications when removed. It is unfortunate since
@@ -802,7 +802,7 @@ int inet_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
802{ 802{
803 struct sock *sk = sock->sk; 803 struct sock *sk = sock->sk;
804 int err = 0; 804 int err = 0;
805 struct net *net = sk->sk_net; 805 struct net *net = sock_net(sk);
806 806
807 switch (cmd) { 807 switch (cmd) {
808 case SIOCGSTAMP: 808 case SIOCGSTAMP:
@@ -1132,7 +1132,7 @@ int inet_sk_rebuild_header(struct sock *sk)
1132 }; 1132 };
1133 1133
1134 security_sk_classify_flow(sk, &fl); 1134 security_sk_classify_flow(sk, &fl);
1135 err = ip_route_output_flow(sk->sk_net, &rt, &fl, sk, 0); 1135 err = ip_route_output_flow(sock_net(sk), &rt, &fl, sk, 0);
1136} 1136}
1137 if (!err) 1137 if (!err)
1138 sk_setup_caps(sk, &rt->u.dst); 1138 sk_setup_caps(sk, &rt->u.dst);