From 235754375395e2d3c317cc61d3bdb885d7da5ae8 Mon Sep 17 00:00:00 2001 From: Gleb Smirnoff Date: Sun, 28 Sep 2014 07:43:38 +0000 Subject: [PATCH] Convert to if_inc_counter() last remnantes of bare access to struct ifnet counters. --- sys/net/if_lagg.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/net/if_lagg.c b/sys/net/if_lagg.c index 834b5612e7a5..d58fb3916ad7 100644 --- a/sys/net/if_lagg.c +++ b/sys/net/if_lagg.c @@ -1485,7 +1485,7 @@ lagg_transmit(struct ifnet *ifp, struct mbuf *m) if (sc->sc_proto == LAGG_PROTO_NONE || sc->sc_count == 0) { LAGG_RUNLOCK(sc, &tracker); m_freem(m); - ifp->if_oerrors++; + if_inc_counter(ifp, IFCOUNTER_OERRORS, 1); return (ENXIO); } @@ -1495,7 +1495,7 @@ lagg_transmit(struct ifnet *ifp, struct mbuf *m) LAGG_RUNLOCK(sc, &tracker); if (error != 0) - ifp->if_oerrors++; + if_inc_counter(ifp, IFCOUNTER_OERRORS, 1); return (error); }