diff options
author | andrew hendry <andrew.hendry@gmail.com> | 2010-04-17 14:17:32 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-04-21 16:31:50 -0700 |
commit | 2cec6b014da6fb4a40ba1c6556cdf9681ed3f89e (patch) | |
tree | 812d44f58c5b0a596db203d75bfd7891d884b8b1 /net/x25 | |
parent | 761172fbf672c5784b2a0d71ca2f4389eb7a2c21 (diff) | |
download | blackbird-op-linux-2cec6b014da6fb4a40ba1c6556cdf9681ed3f89e.tar.gz blackbird-op-linux-2cec6b014da6fb4a40ba1c6556cdf9681ed3f89e.zip |
X25 fix dead unaccepted sockets
1, An X25 program binds and listens
2, calls arrive waiting to be accepted
3, Program exits without accepting
4, Sockets time out but don't get correctly cleaned up
5, cat /proc/net/x25/socket shows the dead sockets with bad inode fields.
This line borrowed from AX25 sets the dying socket so the timers clean up later.
Signed-off-by: Andrew Hendry <andrew.hendry@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/x25')
-rw-r--r-- | net/x25/af_x25.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/x25/af_x25.c b/net/x25/af_x25.c index cbddd0cb83f1..36e84e13c6aa 100644 --- a/net/x25/af_x25.c +++ b/net/x25/af_x25.c @@ -402,6 +402,7 @@ static void __x25_destroy_socket(struct sock *sk) /* * Queue the unaccepted socket for death */ + skb->sk->sk_state = TCP_LISTEN; sock_set_flag(skb->sk, SOCK_DEAD); x25_start_heartbeat(skb->sk); x25_sk(skb->sk)->state = X25_STATE_0; |