Skip to content

Commit

Permalink
[PATCH] softmac: properly check return value of ieee80211softmac_allo…
Browse files Browse the repository at this point in the history
…c_mgt

Properly check return value of ieee80211softmac_alloc_mgt
in ieee80211softmac_disassoc_deauth (patch by Denis Vlasenko)

Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Johannes Berg authored and John W. Linville committed Mar 23, 2006
1 parent 1dc0977 commit bba52d5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/ieee80211/softmac/ieee80211softmac_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ ieee80211softmac_disassoc_deauth(struct ieee80211_disassoc **pkt,
{
/* Allocate Packet */
(*pkt) = (struct ieee80211_disassoc *)ieee80211softmac_alloc_mgt(2);
if (unlikely(pkt == NULL))
if (unlikely((*pkt) == NULL))
return 0;
ieee80211softmac_hdr_3addr(mac, &((*pkt)->header), type, net->bssid, net->bssid);
/* Reason */
Expand Down

0 comments on commit bba52d5

Please sign in to comment.