Skip to content

Commit

Permalink
wl12xx: free ap keys only in ap mode
Browse files Browse the repository at this point in the history
The ap keys should be freed only when removing
ap role (otherwise, some arbitrary data might
get freed).

Signed-off-by: Eliad Peller <eliad@wizery.com>
Signed-off-by: Luciano Coelho <coelho@ti.com>
  • Loading branch information
Eliad Peller authored and Luciano Coelho committed Apr 10, 2012
1 parent 690142e commit 830be7e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/wireless/wl12xx/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2355,10 +2355,10 @@ static void __wl1271_op_remove_interface(struct wl1271 *wl,
for (i = 0; i < CONF_TX_MAX_AC_COUNT; i++)
wl12xx_free_rate_policy(wl,
&wlvif->ap.ucast_rate_idx[i]);
wl1271_free_ap_keys(wl, wlvif);
}

wl12xx_tx_reset_wlvif(wl, wlvif);
wl1271_free_ap_keys(wl, wlvif);
if (wl->last_wlvif == wlvif)
wl->last_wlvif = NULL;
list_del(&wlvif->list);
Expand Down

0 comments on commit 830be7e

Please sign in to comment.