With current code we will print error and try to execute something
If bhdr will be accidantly not NULL, then we will continue with some
trash without letting host knwo about it.
In this case it is better to use assert and send to the host at least panic
notification.
Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
struct ath_hal *ah = sc->sc_ah;
struct ath_tx_buf *bf;
a_uint8_t vap_index, *anbdata;
- ath_beacon_hdr_t *bhdr;
+ ath_beacon_hdr_t *bhdr = NULL;
a_uint32_t anblen;
if (!bc_hdr) {
bhdr = (ath_beacon_hdr_t *)anbdata;
} else {
adf_os_print("found bc_hdr! 0x%x\n", bc_hdr);
+ adf_os_assert(0);
}
vap_index = bhdr->vap_index;