MFC 1.72: bump the scan generation number before iterating

This commit is contained in:
sam 2006-01-29 07:18:09 +00:00
parent 85dc376f3a
commit 8bcd9b14f4

View File

@ -1782,7 +1782,7 @@ ieee80211_timeout_stations(struct ieee80211_node_table *nt)
isadhoc = (ic->ic_opmode == IEEE80211_M_IBSS ||
ic->ic_opmode == IEEE80211_M_AHDEMO);
IEEE80211_SCAN_LOCK(nt);
gen = nt->nt_scangen++;
gen = ++nt->nt_scangen;
IEEE80211_DPRINTF(ic, IEEE80211_MSG_NODE,
"%s: %s scangen %u\n", __func__, nt->nt_name, gen);
restart:
@ -1926,7 +1926,7 @@ ieee80211_iterate_nodes(struct ieee80211_node_table *nt, ieee80211_iter_func *f,
u_int gen;
IEEE80211_SCAN_LOCK(nt);
gen = nt->nt_scangen++;
gen = ++nt->nt_scangen;
restart:
IEEE80211_NODE_LOCK(nt);
TAILQ_FOREACH(ni, &nt->nt_node, ni_list) {