diff options
author | Stefan Sperling <stsp@cvs.openbsd.org> | 2017-12-14 14:27:11 +0000 |
---|---|---|
committer | Stefan Sperling <stsp@cvs.openbsd.org> | 2017-12-14 14:27:11 +0000 |
commit | 09542dd21d6431aefda4c69fdac9d48854d039cd (patch) | |
tree | 6a178fe7368f7200834659bddba5e6cf7dc1b448 /sys/net80211/ieee80211_output.c | |
parent | 180e58c91ba2c116ad7da261ab12aa3ab6995859 (diff) |
Stop printing debug info about stations leaving a wifi network when
we aren't running in hostap or ibss mode.
Diffstat (limited to 'sys/net80211/ieee80211_output.c')
-rw-r--r-- | sys/net80211/ieee80211_output.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/sys/net80211/ieee80211_output.c b/sys/net80211/ieee80211_output.c index 3dbb6826e76..fffd3b7e6a1 100644 --- a/sys/net80211/ieee80211_output.c +++ b/sys/net80211/ieee80211_output.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ieee80211_output.c,v 1.120 2017/12/11 22:23:00 stsp Exp $ */ +/* $OpenBSD: ieee80211_output.c,v 1.121 2017/12/14 14:27:10 stsp Exp $ */ /* $NetBSD: ieee80211_output.c,v 1.13 2004/05/31 11:02:55 dyoung Exp $ */ /*- @@ -1677,11 +1677,12 @@ ieee80211_send_mgmt(struct ieee80211com *ic, struct ieee80211_node *ni, if ((m = ieee80211_get_deauth(ic, ni, arg1)) == NULL) senderr(ENOMEM, is_tx_nombuf); - if (ifp->if_flags & IFF_DEBUG) { + if ((ifp->if_flags & IFF_DEBUG) && + (ic->ic_opmode == IEEE80211_M_HOSTAP || + ic->ic_opmode == IEEE80211_M_IBSS)) printf("%s: station %s deauthenticate (reason %d)\n", ifp->if_xname, ether_sprintf(ni->ni_macaddr), arg1); - } break; case IEEE80211_FC0_SUBTYPE_ASSOC_REQ: @@ -1702,11 +1703,12 @@ ieee80211_send_mgmt(struct ieee80211com *ic, struct ieee80211_node *ni, if ((m = ieee80211_get_disassoc(ic, ni, arg1)) == NULL) senderr(ENOMEM, is_tx_nombuf); - if (ifp->if_flags & IFF_DEBUG) { + if ((ifp->if_flags & IFF_DEBUG) && + (ic->ic_opmode == IEEE80211_M_HOSTAP || + ic->ic_opmode == IEEE80211_M_IBSS)) printf("%s: station %s disassociate (reason %d)\n", ifp->if_xname, ether_sprintf(ni->ni_macaddr), arg1); - } break; case IEEE80211_FC0_SUBTYPE_ACTION: |