iwinfo: properly initialize memory of global nl80211_state, fixes random libnl-tiny...
authorJo-Philipp Wich <jow@openwrt.org>
Mon, 29 Oct 2012 22:11:57 +0000 (22:11 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Mon, 29 Oct 2012 22:11:57 +0000 (22:11 +0000)
SVN-Revision: 34003

package/network/utils/iwinfo/Makefile
package/network/utils/iwinfo/src/iwinfo_nl80211.c

index f05fe4a786ced4fd2b9e8e7bb78f454fc3aa8df4..bbef2bdc85f3ae33148d0edb4cb381031e146003 100644 (file)
@@ -7,7 +7,7 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=libiwinfo
-PKG_RELEASE:=35
+PKG_RELEASE:=36
 
 PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
 PKG_CONFIG_DEPENDS := \
index 304a18b3ecb8582ad204b456adf5cd3ba3d28bdc..763ed61c979da5d93791d57f91cfa1096ba270d8 100644 (file)
@@ -41,6 +41,8 @@ static int nl80211_init(void)
                        goto err;
                }
 
+               memset(nls, 0, sizeof(*nls));
+
                nls->nl_sock = nl_socket_alloc();
                if (!nls->nl_sock) {
                        err = -ENOMEM;