supplicant: Do not reset passphrase when asociation fails
authorSamuel Ortiz <sameo@linux.intel.com>
Thu, 30 Sep 2010 16:20:58 +0000 (18:20 +0200)
committerSamuel Ortiz <sameo@linux.intel.com>
Thu, 30 Sep 2010 16:20:58 +0000 (18:20 +0200)
Resetting the passphrase is redundant as the service will present a
"connect-failed" error string through D-Bus whenever association fails.

plugins/supplicant.c

index 115d2c8..708de31 100644 (file)
@@ -2312,13 +2312,6 @@ static void state_change(struct supplicant_task *task, DBusMessage *msg)
                /* carrier off */
                connman_network_set_connected(task->network, FALSE);
 
-               /*
-                * Reset the passphrase if we're being disconnected before
-                * association/handshake completes.
-                */
-               if (prevstate != WPA_COMPLETED && state == WPA_DISCONNECTED)
-                       connman_network_set_passphrase(task->network, NULL);
-
                if (task->disconnecting == TRUE) {
                        connman_network_unref(task->network);
                        task->disconnecting = FALSE;