ath9k: Fix potential use-after-free.
PATCH 1/1 ath9k: Fix potential use-after-free.
From: Ben Greear <[email protected]>
The ath_debug_stat_tx references bf->bf_mpdu, which
is the skb consumed by ath_tx_complete. So, call
the ath_debug_stat_tx method first.
Signed-off-by Ben Greear <[email protected]>
---
:100644 100644 942be55... 6d41d47... M drivers/net/wireless/ath/ath9k/xmit.c
drivers/net/wireless/ath/ath9k/xmit.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/net/wireless/ath/ath9k/xmit.c +1 -1
@@ -1926,8 +1926,8 @@ static void ath_tx_complete_buf(struct ath_softc *sc, struct ath_buf *bf,else complete (&sc->paprd_complete); }else { -ath_tx_complete (sc, skb, bf->aphy, tx_flags);ath_debug_stat_tx (sc, txq, bf, ts); +ath_tx_complete (sc, skb, bf->aphy, tx_flags); }/*
Signature · 1 line
1.7.2.2
PATCH 1/1 ath9k: Fix potential use-after-free.
Quoted 7 lines · greearb at candelatech.com
From: Ben Greear <[email protected]>
The
ath_debug_stat_txreferencesbf->bf_mpdu, which
is the skb consumed byath_tx_complete. So, call
theath_debug_stat_txmethod first.Signed-off-by Ben Greear <[email protected]>
Acked-by Peter Stuge <[email protected]>