From 00ec535060abd5c4aee59e35e92085d4c3f67902 Mon Sep 17 00:00:00 2001 From: vamsi krishna Date: Fri, 17 Jun 2016 14:34:12 +0530 Subject: [PATCH] WPS: Fix memory leak with wps_ie in wpa_bss_is_wps_candidate() Fix possible memory leak in case if WPS is not enabled on the interface for connection. This path was missed in commit fae7b3726035b57a78aa552378fc5d15402b9ec1 ('WPS: Do not expire probable BSSes for WPS connection'). Signed-off-by: Jouni Malinen --- wpa_supplicant/bss.c | 1 + 1 file changed, 1 insertion(+) diff --git a/wpa_supplicant/bss.c b/wpa_supplicant/bss.c index 8830268d2..3687a2e5a 100644 --- a/wpa_supplicant/bss.c +++ b/wpa_supplicant/bss.c @@ -338,6 +338,7 @@ static int wpa_bss_is_wps_candidate(struct wpa_supplicant *wpa_s, wpabuf_free(wps_ie); return ret; } + wpabuf_free(wps_ie); #endif /* CONFIG_WPS */ return 0;