mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-18 10:35:55 +00:00
bwn(4): Fix trivial null dereference
Reported by: PVS-Studio Sponsored by: Dell EMC Isilon
This commit is contained in:
parent
8d64ff50b3
commit
7013b24d32
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=316582
@ -6754,10 +6754,15 @@ static void
|
||||
bwn_txpwr(void *arg, int npending)
|
||||
{
|
||||
struct bwn_mac *mac = arg;
|
||||
struct bwn_softc *sc = mac->mac_sc;
|
||||
struct bwn_softc *sc;
|
||||
|
||||
if (mac == NULL)
|
||||
return;
|
||||
|
||||
sc = mac->mac_sc;
|
||||
|
||||
BWN_LOCK(sc);
|
||||
if (mac && mac->mac_status >= BWN_MAC_STATUS_STARTED &&
|
||||
if (mac->mac_status >= BWN_MAC_STATUS_STARTED &&
|
||||
mac->mac_phy.set_txpwr != NULL)
|
||||
mac->mac_phy.set_txpwr(mac);
|
||||
BWN_UNLOCK(sc);
|
||||
|
Loading…
Reference in New Issue
Block a user