From: David S. Miller Date: Tue, 17 Jun 2008 10:01:47 +0000 (-0700) Subject: econet: Use sock_orphan() instead of open-coded (and buggy) variant. X-Git-Url: http://git.cdn.openwrt.org/?a=commitdiff_plain;h=0efffaf9d57f54a864b739176d1f659a69486e8b;p=openwrt%2Fstaging%2Fblogic.git econet: Use sock_orphan() instead of open-coded (and buggy) variant. It doesn't grab the sk_callback_lock, it doesn't NULL out the sk->sk_sleep waitqueue pointer, etc. Signed-off-by: David S. Miller --- diff --git a/net/econet/af_econet.c b/net/econet/af_econet.c index 7c9bb13b1539..d35127bb84e1 100644 --- a/net/econet/af_econet.c +++ b/net/econet/af_econet.c @@ -573,9 +573,7 @@ static int econet_release(struct socket *sock) sk->sk_state_change(sk); /* It is useless. Just for sanity. */ - sock->sk = NULL; - sk->sk_socket = NULL; - sock_set_flag(sk, SOCK_DEAD); + sock_orphan(sk); /* Purge queues */