浏览代码

iwlwifi: fix double assign in iwl_start_tx_ba_trans_ready()

"vif" is assigned twice.  We can remove the first one.

This silences a Smatch warning that "ctx" could be one step past the
end of the priv->contexts[] array.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Dan Carpenter 14 年之前
父节点
当前提交
427977ab2e
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/net/wireless/iwlwifi/iwl-core.c

+ 1 - 1
drivers/net/wireless/iwlwifi/iwl-core.c

@@ -1842,7 +1842,7 @@ void iwl_start_tx_ba_trans_ready(struct iwl_priv *priv,
 				 enum iwl_rxon_context_id ctx,
 				 enum iwl_rxon_context_id ctx,
 				 u8 sta_id, u8 tid)
 				 u8 sta_id, u8 tid)
 {
 {
-	struct ieee80211_vif *vif = priv->contexts[ctx].vif;
+	struct ieee80211_vif *vif;
 	u8 *addr = priv->stations[sta_id].sta.sta.addr;
 	u8 *addr = priv->stations[sta_id].sta.sta.addr;
 
 
 	if (ctx == NUM_IWL_RXON_CTX)
 	if (ctx == NUM_IWL_RXON_CTX)