wifi: fix cancelling WPS during pending ProcessCredentials

When we cancel WPS, we must cancel the GCancellable. Otherwise,
ProcessCredentials will return and proceed with Start.

Fixes: 9bfb4f0d09
This commit is contained in:
Thomas Haller 2017-06-14 13:52:40 +02:00
parent be3d897758
commit 6e5cc2b24f

View file

@ -866,8 +866,8 @@ _wps_start (NMSupplicantInterface *self,
_LOGT ("wps: cancel previous enrollment...");
data->is_cancelling = TRUE;
if (!data->cancellable)
data->cancellable = g_cancellable_new ();
nm_clear_g_cancellable (&data->cancellable);
data->cancellable = g_cancellable_new ();
g_signal_handlers_disconnect_by_data (data->proxy, self);
g_dbus_proxy_call (data->proxy,
"Cancel",