]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
Bluetooth: Fix memory leak in hci_req_sync_complete()
authorDmitry Antipov <dmantipov@yandex.ru>
Tue, 2 Apr 2024 11:32:05 +0000 (14:32 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Apr 2024 09:19:25 +0000 (11:19 +0200)
commit9ab5e44b9bac946bd49fd63264a08cd1ea494e76
tree03e39a37c3a45d501533c80b08f6e3d09d6b8001
parenta9cd92bc051f4a8eba0faee62011d4c7a5b98f0b
Bluetooth: Fix memory leak in hci_req_sync_complete()

commit 45d355a926ab40f3ae7bc0b0a00cb0e3e8a5a810 upstream.

In 'hci_req_sync_complete()', always free the previous sync
request state before assigning reference to a new one.

Reported-by: syzbot+39ec16ff6cc18b1d066d@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=39ec16ff6cc18b1d066d
Cc: stable@vger.kernel.org
Fixes: f60cb30579d3 ("Bluetooth: Convert hci_req_sync family of function to new request API")
Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/bluetooth/hci_request.c