Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 21 Apr 2013 00:41:16 +0000 (UTC)
From:      Adrian Chadd <adrian@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r249715 - head/sys/dev/ath
Message-ID:  <201304210041.r3L0fGMW057353@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: adrian
Date: Sun Apr 21 00:41:15 2013
New Revision: 249715
URL: http://svnweb.freebsd.org/changeset/base/249715

Log:
  When doing BAW tracking, don't dereference a NULL pointer if the BAW
  slot is actually NULL.

Modified:
  head/sys/dev/ath/if_ath_tx.c

Modified: head/sys/dev/ath/if_ath_tx.c
==============================================================================
--- head/sys/dev/ath/if_ath_tx.c	Sat Apr 20 23:33:51 2013	(r249714)
+++ head/sys/dev/ath/if_ath_tx.c	Sun Apr 21 00:41:15 2013	(r249715)
@@ -2590,7 +2590,8 @@ ath_tx_update_baw(struct ath_softc *sc, 
 		    __func__,
 		    bf, SEQNO(bf->bf_state.bfs_seqno),
 		    tid->tx_buf[cindex],
-		    SEQNO(tid->tx_buf[cindex]->bf_state.bfs_seqno));
+		    (tid->tx_buf[cindex] != NULL) ?
+		      SEQNO(tid->tx_buf[cindex]->bf_state.bfs_seqno) : -1);
 	}
 
 	tid->tx_buf[cindex] = NULL;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201304210041.r3L0fGMW057353>