]> git.hungrycats.org Git - linux/commit
Bluetooth: btmtk: fix URB leak in alloc_mtk_intr_urb error path
authorZhao Dongdong <zhaodongdong@kylinos.cn>
Thu, 4 Jun 2026 11:46:40 +0000 (19:46 +0800)
committerLuiz Augusto von Dentz <luiz.von.dentz@intel.com>
Thu, 11 Jun 2026 18:24:40 +0000 (14:24 -0400)
commitf396f4005180928cd9e15e352a6512865d3bc908
treec6aa58c84fc73a80a72c755d1dcc87f19b00c117
parent5edcc018fa6e80b2c478454a4a8229c23d67c181
Bluetooth: btmtk: fix URB leak in alloc_mtk_intr_urb error path

When btmtk_isopkt_pad() fails, the previously allocated URB is not freed,
leaking the urb structure. Add usb_free_urb() before returning the error.

Fixes: ceac1cb0259d ("Bluetooth: btusb: mediatek: add ISO data transmission functions")
Signed-off-by: Zhao Dongdong <zhaodongdong@kylinos.cn>
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
drivers/bluetooth/btmtk.c