aboutsummaryrefslogtreecommitdiffstats
path: root/package
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@nbd.name>2018-05-03 12:38:20 +0200
committerFelix Fietkau <nbd@nbd.name>2018-05-03 12:38:33 +0200
commit3a456683e5da7ed3a26ffb71e1dbbf1d1db0d036 (patch)
tree6377b54c4447f88c349e9ea88cc1f6df77133db6 /package
parent58f7b5b96c301176d639540df4723c798af2a999 (diff)
downloadupstream-3a456683e5da7ed3a26ffb71e1dbbf1d1db0d036.tar.gz
upstream-3a456683e5da7ed3a26ffb71e1dbbf1d1db0d036.tar.bz2
upstream-3a456683e5da7ed3a26ffb71e1dbbf1d1db0d036.zip
hostapd: fix a mesh mode crash with CONFIG_TAXONOMY enabled
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'package')
-rw-r--r--package/network/services/hostapd/patches/022-mesh-fix-crash-with-CONFIG_TAXONOMY-enabled.patch23
1 files changed, 23 insertions, 0 deletions
diff --git a/package/network/services/hostapd/patches/022-mesh-fix-crash-with-CONFIG_TAXONOMY-enabled.patch b/package/network/services/hostapd/patches/022-mesh-fix-crash-with-CONFIG_TAXONOMY-enabled.patch
new file mode 100644
index 0000000000..bbc4672f9c
--- /dev/null
+++ b/package/network/services/hostapd/patches/022-mesh-fix-crash-with-CONFIG_TAXONOMY-enabled.patch
@@ -0,0 +1,23 @@
+From: Felix Fietkau <nbd@nbd.name>
+Date: Thu, 3 May 2018 12:34:31 +0200
+Subject: [PATCH] mesh: fix crash with CONFIG_TAXONOMY enabled
+
+wpa_s->ifmsh needs to be allocated using hostapd_alloc_iface() instead
+of a direct call to os_zalloc, otherwise the linked list for station
+taxonomy items remains uninitialized, leading to a crash on the first
+attempt to traverse that list
+
+Signed-off-by: Felix Fietkau <nbd@nbd.name>
+---
+
+--- a/wpa_supplicant/mesh.c
++++ b/wpa_supplicant/mesh.c
+@@ -216,7 +216,7 @@ static int wpa_supplicant_mesh_init(stru
+ return 0;
+ }
+
+- wpa_s->ifmsh = ifmsh = os_zalloc(sizeof(*wpa_s->ifmsh));
++ wpa_s->ifmsh = ifmsh = hostapd_alloc_iface();
+ if (!ifmsh)
+ return -ENOMEM;
+