]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
P2P: Fix memory leak in SD service entries
authorJouni Malinen <jouni.malinen@atheros.com>
Mon, 28 Jun 2010 06:26:47 +0000 (23:26 -0700)
committerJouni Malinen <j@w1.fi>
Thu, 9 Sep 2010 14:17:19 +0000 (07:17 -0700)
Need to flush stored service entries when wpa_supplicant is being
terminated.

wpa_supplicant/p2p_supplicant.c

index 6d142c520e70a0e35341c50bf9441dd8ca4254cf..a71e9f9aa2b291e25901b4412e51426842270285 100644 (file)
@@ -2190,6 +2190,8 @@ void wpas_p2p_deinit_global(struct wpa_global *global)
 
        /* Remove remaining P2P group interfaces */
        wpa_s = global->ifaces;
+       if (wpa_s)
+               wpas_p2p_service_flush(wpa_s);
        while (wpa_s && wpa_s->p2p_group_interface != NOT_P2P_GROUP_INTERFACE)
                wpa_s = wpa_s->next;
        while (wpa_s) {