From 7784ca7234be2b854f298f4e150ecaa5212c0301 Mon Sep 17 00:00:00 2001 From: Tomasz Bursztyka Date: Wed, 26 Jan 2011 10:09:44 +0200 Subject: [PATCH] gsupplicant: Disconnect request might not need to go through RemoveNetwork call --- gsupplicant/supplicant.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gsupplicant/supplicant.c b/gsupplicant/supplicant.c index bed049a..8c91a83 100644 --- a/gsupplicant/supplicant.c +++ b/gsupplicant/supplicant.c @@ -2835,6 +2835,12 @@ static void interface_disconnect_result(const char *error, if (error != NULL && data->callback != NULL) data->callback(-EIO, data->interface, data->user_data); + /* If we are disconnecting from previous WPS successful + * association. i.e.: it did not went through AddNetwork, + * and interface->network_path was never set. */ + if (data->interface->network_path == NULL) + return; + network_remove(data); } -- 2.7.4