提交 ce845377 编写于 作者: L Linus Torvalds

Revert "Bluetooth: fix shutdown on SCO sockets"

This reverts commit f21ca5ff.

Quoth Gustavo F. Padovan:
  "Commit f21ca5ff can cause a NULL
   dereference if we call shutdown in a bluetooth SCO socket and doesn't
   wait the shutdown completion to call close().  Please revert it.  I
   may have a fix for it soon, but we don't have time anymore, so revert
   is the way to go.  ;)"
Requested-by: NGustavo F. Padovan <padovan@profusion.mobi>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 0e6f76c7
......@@ -369,15 +369,6 @@ static void __sco_sock_close(struct sock *sk)
case BT_CONNECTED:
case BT_CONFIG:
if (sco_pi(sk)->conn) {
sk->sk_state = BT_DISCONN;
sco_sock_set_timer(sk, SCO_DISCONN_TIMEOUT);
hci_conn_put(sco_pi(sk)->conn->hcon);
sco_pi(sk)->conn = NULL;
} else
sco_chan_del(sk, ECONNRESET);
break;
case BT_CONNECT:
case BT_DISCONN:
sco_chan_del(sk, ECONNRESET);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册