Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ddcd0f41 authored by Vinicius Costa Gomes's avatar Vinicius Costa Gomes Committed by Johan Hedberg
Browse files

Bluetooth: Fix checking the wrong flag when accepting a socket



Most probably a typo, the check should have been for BT_SK_DEFER_SETUP
instead of BT_DEFER_SETUP (which right now only represents a socket
option).

Signed-off-by: default avatarVinicius Costa Gomes <vinicius.gomes@openbossa.org>
Acked-by: default avatarAndrei Emeltchenko <andrei.emeltchenko@intel.com>
Signed-off-by: default avatarGustavo Padovan <gustavo.padovan@collabora.co.uk>
parent fcb6ff5e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -210,7 +210,7 @@ struct sock *bt_accept_dequeue(struct sock *parent, struct socket *newsock)
		}

		if (sk->sk_state == BT_CONNECTED || !newsock ||
		    test_bit(BT_DEFER_SETUP, &bt_sk(parent)->flags)) {
		    test_bit(BT_SK_DEFER_SETUP, &bt_sk(parent)->flags)) {
			bt_accept_unlink(sk);
			if (newsock)
				sock_graft(sk, newsock);