linux-brain/arch/m68k/emu
Pavel Skripkin 67da2d9c9e m68k: emu: Fix invalid free in nfeth_cleanup()
[ Upstream commit 761608f5cf70e8876c2f0e39ca54b516bdcb7c12 ]

In the for loop all nfeth_dev array members should be freed, not only
the first one.  Freeing only the first array member can cause
double-free bugs and memory leaks.

Fixes: 9cd7b14831 ("m68k/atari: ARAnyM - Add support for network access")
Signed-off-by: Pavel Skripkin <paskripkin@gmail.com>
Link: https://lore.kernel.org/r/20210705204727.10743-1-paskripkin@gmail.com
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2021-09-15 09:47:28 +02:00
..
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
natfeat.c m68k: Mark functions only called from setup_arch() __init 2013-11-26 11:08:54 +01:00
nfblock.c m68k: set proper major_num when specifying module param major_num 2019-02-06 12:50:40 -07:00
nfcon.c m68k/atari: ARAnyM - Always use physical addresses in NatFeat calls 2013-08-23 12:49:01 +02:00
nfeth.c m68k: emu: Fix invalid free in nfeth_cleanup() 2021-09-15 09:47:28 +02:00