]> git.openfabrics.org - ~emulex/infiniband.git/commitdiff
Bluetooth: Remove redundant call to rfcomm_send_disc
authorDean Jenkins <Dean_Jenkins@mentor.com>
Thu, 28 Feb 2013 14:21:57 +0000 (14:21 +0000)
committerGustavo Padovan <gustavo.padovan@collabora.co.uk>
Fri, 8 Mar 2013 13:40:25 +0000 (10:40 -0300)
In rfcomm_session_del() remove the redundant call to
rfcomm_send_disc() because it is not possible for the
session to be in BT_CONNECTED state during deletion
of the session.

Signed-off-by: Dean Jenkins <Dean_Jenkins@mentor.com>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
net/bluetooth/rfcomm/core.c

index 75b7bbd8acb7bc5afea2f24d2b64607ccdde5e54..c7e88761d3b72c08335a42e920a8ad351d9b8240 100644 (file)
@@ -627,9 +627,6 @@ static struct rfcomm_session *rfcomm_session_del(struct rfcomm_session *s)
 
        list_del(&s->list);
 
-       if (state == BT_CONNECTED)
-               rfcomm_send_disc(s, 0);
-
        rfcomm_session_clear_timer(s);
        sock_release(s->sock);
        kfree(s);