From: Gustavo F. Padovan Date: Sat, 15 Oct 2011 21:03:15 +0000 (-0300) Subject: Bluetooth: Fix missing cmd_status in mgmt X-Git-Tag: next-20111025~56^2~5 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=e5b82e58922749e79b84b85cfc6845cbfd1908ed;p=karo-tx-linux.git Bluetooth: Fix missing cmd_status in mgmt set_service_cache() was missing a cmd_status for the error case. Signed-off-by: Gustavo F. Padovan --- diff --git a/net/bluetooth/mgmt.c b/net/bluetooth/mgmt.c index 080cfb6347e8..9ffd7c3dbb3e 100644 --- a/net/bluetooth/mgmt.c +++ b/net/bluetooth/mgmt.c @@ -897,6 +897,9 @@ static int set_service_cache(struct sock *sk, u16 index, unsigned char *data, if (err == 0) err = cmd_complete(sk, index, MGMT_OP_SET_SERVICE_CACHE, NULL, 0); + else + cmd_status(sk, index, MGMT_OP_SET_SERVICE_CACHE, -err); + hci_dev_unlock_bh(hdev); hci_dev_put(hdev);