rtl818x: fix potential use after free
authorPan Bian <bianpan2016@163.com>
Thu, 29 Nov 2018 10:48:10 +0000 (18:48 +0800)
committerKalle Valo <kvalo@codeaurora.org>
Thu, 13 Dec 2018 15:03:06 +0000 (17:03 +0200)
commitafbb1947db94eacc5a13302eee88a9772fb78935
tree6d66e0698bb99b77cea6b052c13c8b49fe76e169
parent662a7b078cff6ab246d875775af7affedcf6e2d5
rtl818x: fix potential use after free

entry is released via usb_put_urb just after calling usb_submit_urb.
However, entry is used if the submission fails, resulting in a use after
free bug. The patch fixes this.

Signed-off-by: Pan Bian <bianpan2016@163.com>
ACKed-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/realtek/rtl818x/rtl8187/dev.c