mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-05 22:28:00 +00:00
rtlwifi: rtl8192cu: Free ieee80211_hw if probing fails
In case of an error, no one will use the allocated structure. Call ieee80211_free_hw, same as in rtl_usb_disconnect. Signed-off-by: Reto Schneider <code@reto-schneider.ch> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Link: https://lore.kernel.org/r/20200622132113.14508-4-code@reto-schneider.ch
This commit is contained in:
parent
03128643eb
commit
a7f7c15e94
1 changed files with 1 additions and 0 deletions
|
@ -1087,6 +1087,7 @@ error_out2:
|
||||||
usb_put_dev(udev);
|
usb_put_dev(udev);
|
||||||
complete(&rtlpriv->firmware_loading_complete);
|
complete(&rtlpriv->firmware_loading_complete);
|
||||||
kfree(rtlpriv->usb_data);
|
kfree(rtlpriv->usb_data);
|
||||||
|
ieee80211_free_hw(hw);
|
||||||
return -ENODEV;
|
return -ENODEV;
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL(rtl_usb_probe);
|
EXPORT_SYMBOL(rtl_usb_probe);
|
||||||
|
|
Loading…
Add table
Reference in a new issue