since we pass received management frames to net80211, net80211
may send replies (like deauth/disassoc), so we just call
IF_PURGE(&ic->ic_mgtq) in {ipw,iwi}_start just to be on the
safe side of things (so we don't leak mbufs).
-/* $OpenBSD: if_ipw.c,v 1.74 2008/08/27 09:05:03 damien Exp $ */
+/* $OpenBSD: if_ipw.c,v 1.75 2008/08/27 09:28:38 damien Exp $ */
/*-
* Copyright (c) 2004-2008
struct ieee80211_node *ni;
struct mbuf *m;
- if (ic->ic_state != IEEE80211_S_RUN)
- return;
-
for (;;) {
+ IF_PURGE(&ic->ic_mgtq);
+
+ if (ic->ic_state != IEEE80211_S_RUN)
+ return;
IFQ_POLL(&ifp->if_snd, m);
if (m == NULL)
break;
-/* $OpenBSD: if_iwi.c,v 1.88 2008/08/27 09:05:03 damien Exp $ */
+/* $OpenBSD: if_iwi.c,v 1.89 2008/08/27 09:28:38 damien Exp $ */
/*-
* Copyright (c) 2004-2006
struct mbuf *m0;
struct ieee80211_node *ni;
- if (ic->ic_state != IEEE80211_S_RUN)
- return;
-
for (;;) {
+ IF_PURGE(&ic->ic_mgtq);
+
+ if (ic->ic_state != IEEE80211_S_RUN)
+ return;
IFQ_POLL(&ifp->if_snd, m0);
if (m0 == NULL)
break;