diff options
author | rpaulo <rpaulo@FreeBSD.org> | 2010-04-07 17:49:47 +0000 |
---|---|---|
committer | rpaulo <rpaulo@FreeBSD.org> | 2010-04-07 17:49:47 +0000 |
commit | 3777315b3a69dd7b7d76210bc9dd16809e035be6 (patch) | |
tree | adf35ce11931f75306a456cebeee9437af104eb6 /sys/dev | |
parent | 7ff3f3cc8a52659bfb2a6eb300803f7cf334f45a (diff) | |
download | FreeBSD-src-3777315b3a69dd7b7d76210bc9dd16809e035be6.zip FreeBSD-src-3777315b3a69dd7b7d76210bc9dd16809e035be6.tar.gz |
Avoid NULL deref.
Submitted by: gavin
MFC after: 1 month
Diffstat (limited to 'sys/dev')
-rw-r--r-- | sys/dev/bwi/if_bwi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/bwi/if_bwi.c b/sys/dev/bwi/if_bwi.c index c77004d..96c5cc6 100644 --- a/sys/dev/bwi/if_bwi.c +++ b/sys/dev/bwi/if_bwi.c @@ -3368,10 +3368,10 @@ _bwi_txeof(struct bwi_softc *sc, uint16_t tx_id, int acked, int data_txcnt) bus_dmamap_unload(sc->sc_buf_dtag, tb->tb_dmap); ni = tb->tb_ni; - vap = ni->ni_vap; if (tb->tb_ni != NULL) { const struct bwi_txbuf_hdr *hdr = mtod(tb->tb_mbuf, const struct bwi_txbuf_hdr *); + vap = ni->ni_vap; /* NB: update rate control only for unicast frames */ if (hdr->txh_mac_ctrl & htole32(BWI_TXH_MAC_C_ACK)) { |