Parcourir la source

P2P: Clear get_pref_freq_list_override on P2P Device

Clear the get_pref_freq_list_override in p2p_ctrl_flush(). This fixes
the case when a dedicated P2P device interface is used.

Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
Andrei Otcheretianski il y a 7 ans
Parent
commit
d02e4c8ac8
1 fichiers modifiés avec 6 ajouts et 0 suppressions
  1. 6 0
      wpa_supplicant/ctrl_iface.c

+ 6 - 0
wpa_supplicant/ctrl_iface.c

@@ -6651,6 +6651,12 @@ static void p2p_ctrl_flush(struct wpa_supplicant *wpa_s)
 {
 	os_memset(wpa_s->p2p_auth_invite, 0, ETH_ALEN);
 	wpa_s->force_long_sd = 0;
+
+#ifdef CONFIG_TESTING_OPTIONS
+	os_free(wpa_s->get_pref_freq_list_override);
+	wpa_s->get_pref_freq_list_override = NULL;
+#endif /* CONFIG_TESTING_OPTIONS */
+
 	wpas_p2p_stop_find(wpa_s);
 	wpa_s->parent->p2ps_method_config_any = 0;
 	if (wpa_s->global->p2p)