Revert "ax25: Fix std timer socket destroy handling."

This reverts commit 30902dc3cb.

It causes all kinds of problems, based upon a report by
Bernard (f6bvp) and analysis by Jarek Poplawski.

Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
David S. Miller 2008-10-06 12:48:29 -07:00
parent 0523820482
commit 88a944eef8

View file

@ -39,9 +39,11 @@ void ax25_std_heartbeat_expiry(ax25_cb *ax25)
switch (ax25->state) { switch (ax25->state) {
case AX25_STATE_0: case AX25_STATE_0:
if (!sk || /* Magic here: If we listen() and a new link dies before it
sock_flag(sk, SOCK_DESTROY) || is accepted() it isn't 'dead' so doesn't get removed. */
sock_flag(sk, SOCK_DEAD)) { if (!sk || sock_flag(sk, SOCK_DESTROY) ||
(sk->sk_state == TCP_LISTEN &&
sock_flag(sk, SOCK_DEAD))) {
if (sk) { if (sk) {
sock_hold(sk); sock_hold(sk);
ax25_destroy_socket(ax25); ax25_destroy_socket(ax25);