提交 bdc98b13 编写于 作者: S Sharon Dvir 提交者: Luca Coelho

iwlwifi: mvm: check if vif is NULL before using it

wdev_to_ieee80211_vif() might return NULL.
Check that vif != NULL before dereferencing it.
Signed-off-by: NSharon Dvir <sharon.dvir@intel.com>
Signed-off-by: NLuca Coelho <luciano.coelho@intel.com>
上级 36064795
......@@ -467,6 +467,8 @@ struct iwl_mvm_vif {
static inline struct iwl_mvm_vif *
iwl_mvm_vif_from_mac80211(struct ieee80211_vif *vif)
{
if (!vif)
return NULL;
return (void *)vif->drv_priv;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册