diff options
| author | James Morris <jmorris@intercode.com.au> | 2003-03-02 12:57:04 -0800 |
|---|---|---|
| committer | David S. Miller <davem@nuts.ninka.net> | 2003-03-02 12:57:04 -0800 |
| commit | bd698d6854049c0d493956b8cb4265053ae0a248 (patch) | |
| tree | 9e6bd193e3f6da90449b9bd300fa359f270de029 /net/ax25/ax25_std_timer.c | |
| parent | ffbd6a98b8b781b78ad7e2afe7cb84a4a0ee0b68 (diff) | |
[NET]: Convert volatile char socket flags to real bitops mask, work by Pedro Hortas.
Diffstat (limited to 'net/ax25/ax25_std_timer.c')
| -rw-r--r-- | net/ax25/ax25_std_timer.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/ax25/ax25_std_timer.c b/net/ax25/ax25_std_timer.c index 957f5e5fec81..604b4fe3ee4a 100644 --- a/net/ax25/ax25_std_timer.c +++ b/net/ax25/ax25_std_timer.c @@ -37,7 +37,7 @@ void ax25_std_heartbeat_expiry(ax25_cb *ax25) case AX25_STATE_0: /* Magic here: If we listen() and a new link dies before it is accepted() it isn't 'dead' so doesn't get removed. */ - if (ax25->sk == NULL || ax25->sk->destroy || (ax25->sk->state == TCP_LISTEN && ax25->sk->dead)) { + if (ax25->sk == NULL || test_bit(SOCK_DESTROY, &ax25->sk->flags) || (ax25->sk->state == TCP_LISTEN && test_bit(SOCK_DEAD, &ax25->sk->flags))) { ax25_destroy_socket(ax25); return; } @@ -94,9 +94,9 @@ void ax25_std_idletimer_expiry(ax25_cb *ax25) ax25->sk->state = TCP_CLOSE; ax25->sk->err = 0; ax25->sk->shutdown |= SEND_SHUTDOWN; - if (!ax25->sk->dead) + if (!test_bit(SOCK_DEAD, &ax25->sk->flags)) ax25->sk->state_change(ax25->sk); - ax25->sk->dead = 1; + __set_bit(SOCK_DEAD, &ax25->sk->flags); } } |
