diff options
author | Stefan Sperling <stsp@cvs.openbsd.org> | 2017-01-09 09:31:19 +0000 |
---|---|---|
committer | Stefan Sperling <stsp@cvs.openbsd.org> | 2017-01-09 09:31:19 +0000 |
commit | 9f83f3e0aeaffc9b01c3f76790a08bfdbd33f830 (patch) | |
tree | b089756126bbb9cb36f03aa0240aa509decdae74 /sys/net80211/ieee80211_node.c | |
parent | 2e4e0c37e5613aadae91ae14e4cca82ef60739d5 (diff) |
The point of ieee80211_node_leave() is to place the node in COLLECT state.
Return early and do nothing if the node is already in COLLECT state upon
entry to this function.
Diffstat (limited to 'sys/net80211/ieee80211_node.c')
-rw-r--r-- | sys/net80211/ieee80211_node.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/net80211/ieee80211_node.c b/sys/net80211/ieee80211_node.c index 13d6ea0b076..f9c2d55c55c 100644 --- a/sys/net80211/ieee80211_node.c +++ b/sys/net80211/ieee80211_node.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ieee80211_node.c,v 1.107 2017/01/09 09:30:47 stsp Exp $ */ +/* $OpenBSD: ieee80211_node.c,v 1.108 2017/01/09 09:31:18 stsp Exp $ */ /* $NetBSD: ieee80211_node.c,v 1.14 2004/05/09 09:18:47 dyoung Exp $ */ /*- @@ -1680,6 +1680,9 @@ ieee80211_node_leave(struct ieee80211com *ic, struct ieee80211_node *ni) { if (ic->ic_opmode != IEEE80211_M_HOSTAP) panic("not in ap mode, mode %u", ic->ic_opmode); + + if (ni->ni_state == IEEE80211_STA_COLLECT) + return; /* * If node wasn't previously associated all we need to do is * reclaim the reference. |