[iwm] free node reference if rxparams addition fails.
This commit is contained in:
parent
9ad221a558
commit
e8bb2e7961
@ -2994,8 +2994,11 @@ iwm_mvm_rx_rx_mpdu(struct iwm_softc *sc,
|
||||
/* rssi is in 1/2db units */
|
||||
rxs.c_rssi = rssi * 2;
|
||||
rxs.c_nf = sc->sc_noise;
|
||||
if (ieee80211_add_rx_params(m, &rxs) == 0)
|
||||
if (ieee80211_add_rx_params(m, &rxs) == 0) {
|
||||
if (ni)
|
||||
ieee80211_free_node(ni);
|
||||
goto fail;
|
||||
}
|
||||
|
||||
if (ieee80211_radiotap_active_vap(vap)) {
|
||||
struct iwm_rx_radiotap_header *tap = &sc->sc_rxtap;
|
||||
@ -3042,7 +3045,8 @@ iwm_mvm_rx_rx_mpdu(struct iwm_softc *sc,
|
||||
|
||||
return;
|
||||
|
||||
fail: counter_u64_add(ic->ic_ierrors, 1);
|
||||
fail:
|
||||
counter_u64_add(ic->ic_ierrors, 1);
|
||||
}
|
||||
|
||||
static int
|
||||
|
Loading…
Reference in New Issue
Block a user