]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
Use key=NULL when clearing PTK with set_key
authorJouni Malinen <j@w1.fi>
Sun, 9 Jan 2011 10:12:48 +0000 (12:12 +0200)
committerJouni Malinen <j@w1.fi>
Sun, 9 Jan 2011 10:12:48 +0000 (12:12 +0200)
The key clearing operations are using NULL everywhere else, so make
this consistent with other callers.

src/ap/wpa_auth.c

index 397fa9834515a0ce3eefb41acec0d8c0d525887f..6537bdea6fff46339974194bdf0296d1b09a4220 100644 (file)
@@ -1314,8 +1314,7 @@ void wpa_remove_ptk(struct wpa_state_machine *sm)
 {
        sm->PTK_valid = FALSE;
        os_memset(&sm->PTK, 0, sizeof(sm->PTK));
-       wpa_auth_set_key(sm->wpa_auth, 0, WPA_ALG_NONE, sm->addr, 0, (u8 *) "",
-                        0);
+       wpa_auth_set_key(sm->wpa_auth, 0, WPA_ALG_NONE, sm->addr, 0, NULL, 0);
        sm->pairwise_set = FALSE;
        eloop_cancel_timeout(wpa_rekey_ptk, sm->wpa_auth, sm);
 }