Commit c44649216522cd607a4027d2ebf4a8147d3fa94c

Authored by Eric Dumazet
Committed by David S. Miller
1 parent ca55158c6e

tcp: use correct net ns in cookie_v4_check()

Its better to make a route lookup in appropriate namespace.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

net/ipv4/syncookies.c
... ... @@ -347,7 +347,7 @@
347 347 { .sport = th->dest,
348 348 .dport = th->source } } };
349 349 security_req_classify_flow(req, &fl);
350   - if (ip_route_output_key(&init_net, &rt, &fl)) {
  350 + if (ip_route_output_key(sock_net(sk), &rt, &fl)) {
351 351 reqsk_free(req);
352 352 goto out;
353 353 }