summaryrefslogtreecommitdiffstats
path: root/net/ipv4
diff options
context:
space:
mode:
authorBalazs Scheidler <bazsi@balabit.hu>2008-11-20 01:07:24 -0800
committerDavid S. Miller <davem@davemloft.net>2008-11-20 01:07:24 -0800
commita134f85c131ffd56720e38af2967ec6265480757 (patch)
tree855f671667da2643274af8d580e16843f4baa393 /net/ipv4
parentb88ed5cc884e4c28d787cf0912b8635376f16a87 (diff)
downloadlinux-a134f85c131ffd56720e38af2967ec6265480757.tar.bz2
TPROXY: fill struct flowi->flags in udp_sendmsg()
udp_sendmsg() didn't fill struct flowi->flags, which means that the route lookup would fail for non-local IPs even if the IP_TRANSPARENT sockopt was set. This prevents sendto() to work properly for UDP sockets, whereas bind(foreign-ip) + connect() + send() worked fine. Signed-off-by: Balazs Scheidler <bazsi@balabit.hu> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r--net/ipv4/udp.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/ipv4/udp.c b/net/ipv4/udp.c
index cf02701ced48..98c1fd09be88 100644
--- a/net/ipv4/udp.c
+++ b/net/ipv4/udp.c
@@ -633,6 +633,7 @@ int udp_sendmsg(struct kiocb *iocb, struct sock *sk, struct msghdr *msg,
.saddr = saddr,
.tos = tos } },
.proto = sk->sk_protocol,
+ .flags = inet_sk_flowi_flags(sk),
.uli_u = { .ports =
{ .sport = inet->sport,
.dport = dport } } };