]> git.baikalelectronics.ru Git - kernel.git/commit
mwifiex: pcie: tighten a check in mwifiex_pcie_process_event_ready()
authorDan Carpenter <dan.carpenter@oracle.com>
Thu, 5 Apr 2018 11:17:19 +0000 (14:17 +0300)
committerKalle Valo <kvalo@codeaurora.org>
Wed, 25 Apr 2018 08:20:36 +0000 (11:20 +0300)
commit3e54ab69bf14e73342e2ae1913aaab1f7befc716
treebd5fff3b53fc14e87875da3f7c35ce40d779392a
parent8fa62068f4e874f7797702c9a29658bca7b4b532
mwifiex: pcie: tighten a check in mwifiex_pcie_process_event_ready()

If "evt_len" is 1 then we try to memcpy() negative 3 bytes and it would
cause memory corruption.

Fixes: b47ea0a8299c ("mwifiex: add support for Marvell pcie8766 chipset")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/marvell/mwifiex/pcie.c