Date: Mon, 22 Aug 2011 16:35:46 +0000 (UTC) From: Adrian Chadd <adrian@FreeBSD.org> To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r225078 - user/adrian/if_ath_tx/sys/dev/ath Message-ID: <201108221635.p7MGZk2m058796@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: adrian Date: Mon Aug 22 16:35:46 2011 New Revision: 225078 URL: http://svn.freebsd.org/changeset/base/225078 Log: Fix a NULL de-reference Modified: user/adrian/if_ath_tx/sys/dev/ath/if_ath.c Modified: user/adrian/if_ath_tx/sys/dev/ath/if_ath.c ============================================================================== --- user/adrian/if_ath_tx/sys/dev/ath/if_ath.c Mon Aug 22 11:22:13 2011 (r225077) +++ user/adrian/if_ath_tx/sys/dev/ath/if_ath.c Mon Aug 22 16:35:46 2011 (r225078) @@ -1883,9 +1883,10 @@ _ath_getbuf_locked(struct ath_softc *sc) DPRINTF(sc, ATH_DEBUG_XMIT, "%s: %s\n", __func__, TAILQ_FIRST(&sc->sc_txbuf) == NULL ? "out of xmit buffers" : "xmit buffer busy"); + } else { + bf->bf_next = NULL; /* XXX just to be sure */ + bf->bf_comp = NULL; /* XXX again, just to be sure */ } - bf->bf_next = NULL; /* XXX just to be sure */ - bf->bf_comp = NULL; /* XXX again, just to be sure */ return bf; }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201108221635.p7MGZk2m058796>