From eb7ddbf108252f7ff30170b7fa62192cfd4cdc99 Mon Sep 17 00:00:00 2001 From: Jouni Malinen Date: Thu, 11 Jul 2013 16:16:52 +0300 Subject: [PATCH] WPS: Stop SSDP service before freeing the pending entries This avoids debug warnings about freeing referenced memory. Signed-hostap: Jouni Malinen --- src/wps/wps_upnp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wps/wps_upnp.c b/src/wps/wps_upnp.c index af63e4db4..bea2b3312 100644 --- a/src/wps/wps_upnp.c +++ b/src/wps/wps_upnp.c @@ -982,6 +982,7 @@ static void upnp_wps_device_stop(struct upnp_wps_device_sm *sm) wpa_printf(MSG_DEBUG, "WPS UPnP: Stop device"); web_listener_stop(sm); + ssdp_listener_stop(sm); upnp_wps_free_msearchreply(&sm->msearch_replies); upnp_wps_free_subscriptions(&sm->subscriptions, NULL); @@ -995,7 +996,6 @@ static void upnp_wps_device_stop(struct upnp_wps_device_sm *sm) if (sm->multicast_sd >= 0) close(sm->multicast_sd); sm->multicast_sd = -1; - ssdp_listener_stop(sm); sm->started = 0; } -- 2.39.2