diff options
Diffstat (limited to 'net/ipv4/ip_output.c')
-rw-r--r-- | net/ipv4/ip_output.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c index 33316b3534ca..171f483b21d5 100644 --- a/net/ipv4/ip_output.c +++ b/net/ipv4/ip_output.c | |||
@@ -355,7 +355,8 @@ int ip_queue_xmit(struct sk_buff *skb) | |||
355 | * itself out. | 355 | * itself out. |
356 | */ | 356 | */ |
357 | security_sk_classify_flow(sk, &fl); | 357 | security_sk_classify_flow(sk, &fl); |
358 | if (ip_route_output_flow(sock_net(sk), &rt, &fl, sk)) | 358 | rt = ip_route_output_flow(sock_net(sk), &fl, sk); |
359 | if (IS_ERR(rt)) | ||
359 | goto no_route; | 360 | goto no_route; |
360 | } | 361 | } |
361 | sk_setup_caps(sk, &rt->dst); | 362 | sk_setup_caps(sk, &rt->dst); |
@@ -1489,7 +1490,8 @@ void ip_send_reply(struct sock *sk, struct sk_buff *skb, struct ip_reply_arg *ar | |||
1489 | .proto = sk->sk_protocol, | 1490 | .proto = sk->sk_protocol, |
1490 | .flags = ip_reply_arg_flowi_flags(arg) }; | 1491 | .flags = ip_reply_arg_flowi_flags(arg) }; |
1491 | security_skb_classify_flow(skb, &fl); | 1492 | security_skb_classify_flow(skb, &fl); |
1492 | if (ip_route_output_key(sock_net(sk), &rt, &fl)) | 1493 | rt = ip_route_output_key(sock_net(sk), &fl); |
1494 | if (IS_ERR(rt)) | ||
1493 | return; | 1495 | return; |
1494 | } | 1496 | } |
1495 | 1497 | ||