hostapd: bump to 2024-09-06 (wip)
[openwrt/staging/xback.git] / package / network / services / hostapd / patches / 052-AP-add-missing-null-pointer-check-in-hostapd_free_ha.patch
1 From: Felix Fietkau <nbd@nbd.name>
2 Date: Wed, 1 May 2024 18:55:24 +0200
3 Subject: [PATCH] AP: add missing null pointer check in hostapd_free_hapd_data
4
5 When called from wpa_supplicant, iface->interfaces can be NULL
6
7 Signed-off-by: Felix Fietkau <nbd@nbd.name>
8 ---
9
10 --- a/src/ap/hostapd.c
11 +++ b/src/ap/hostapd.c
12 @@ -485,7 +485,7 @@ void hostapd_free_hapd_data(struct hosta
13 struct hapd_interfaces *ifaces = hapd->iface->interfaces;
14 size_t i;
15
16 - for (i = 0; i < ifaces->count; i++) {
17 + for (i = 0; ifaces && i < ifaces->count; i++) {
18 struct hostapd_iface *iface = ifaces->iface[i];
19 size_t j;
20