diff options
author | David S. Miller <davem@sunset.davemloft.net> | 2007-08-02 19:23:56 -0700 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-08-02 19:42:28 -0700 |
commit | 3516ffb0fef710749daf288c0fe146503e0cf9d4 (patch) | |
tree | f3e3cd29dd541a457e61152560fe4416642a69bc /net/ipv6/tcp_ipv6.c | |
parent | 1bcabbdb0bdfe8b15b05150a7857646430aaa7f8 (diff) | |
download | kernel_samsung_smdk4412-3516ffb0fef710749daf288c0fe146503e0cf9d4.zip kernel_samsung_smdk4412-3516ffb0fef710749daf288c0fe146503e0cf9d4.tar.gz kernel_samsung_smdk4412-3516ffb0fef710749daf288c0fe146503e0cf9d4.tar.bz2 |
[TCP]: Invoke tcp_sendmsg() directly, do not use inet_sendmsg().
As discovered by Evegniy Polyakov, if we try to sendmsg after
a connection reset, we can do incredibly stupid things.
The core issue is that inet_sendmsg() tries to autobind the
socket, but we should never do that for TCP. Instead we should
just go straight into TCP's sendmsg() code which will do all
of the necessary state and pending socket error checks.
TCP's sendpage already directly vectors to tcp_sendpage(), so this
merely brings sendmsg() in line with that.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv6/tcp_ipv6.c')
-rw-r--r-- | net/ipv6/tcp_ipv6.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/net/ipv6/tcp_ipv6.c b/net/ipv6/tcp_ipv6.c index f10f368..cbdb784 100644 --- a/net/ipv6/tcp_ipv6.c +++ b/net/ipv6/tcp_ipv6.c @@ -2115,7 +2115,6 @@ struct proto tcpv6_prot = { .shutdown = tcp_shutdown, .setsockopt = tcp_setsockopt, .getsockopt = tcp_getsockopt, - .sendmsg = tcp_sendmsg, .recvmsg = tcp_recvmsg, .backlog_rcv = tcp_v6_do_rcv, .hash = tcp_v6_hash, |