[BUGFIX] wifi: mac80211: Fix possible use after free in ieee80211_reconfig_roc

ieee80211_reconfig_roc function incorrectly uses list_for_each_entry
to iterate over the roc list without ensuring safe removal of
elements. Replace list_for_each_entry with list_for_each_entry_safe
to fix it.

type=bugfix
ticket=none
fixes=Ifc02a45a5ce23868dc7e428bad8d0e6996dd10f4

Signed-off-by: Daniel Gabay <daniel.gabay@intel.com>
Change-Id: I17bba3e85644518ecf7d8bc90fc71fb57326d2d5
Reviewed-on: https://gerritwcs.ir.intel.com/c/iwlwifi-stack-dev/+/109487
automatic-review: iil_jenkins iil_jenkins <EC.GER.UNIX.IIL.JENKINS@INTEL.COM>
Reviewed-by: Johannes Berg <johannes.berg@intel.com>
Reviewed-by: Miriam Rachel Korenblit <miriam.rachel.korenblit@intel.com>
tested: iil_jenkins iil_jenkins <EC.GER.UNIX.IIL.JENKINS@INTEL.COM>
x-iwlwifi-stack-dev: 02f49b3df194d6b0b7d24c77355f49e68eb49ec1
2 files changed