Skip to contentSkip to conversation

staging: wlan-ng: remove redundant initialization of variable txresult

PATCH New Colin King 1 participant 1 message Apr 22, 2021

Subsystems (2)
lore
Share & tools
lore

Colin King

author
#0 lore raw

PATCH 1/1 staging: wlan-ng: remove redundant initialization of variable txresult

From: Colin Ian King <[email protected]>

The variable txresult is being initialized with a value that is never read and it is being updated later with a new value. The initialization is redundant and can be removed.

Addresses-Coverity: ("Unused value")

---
 drivers/staging/wlan-ng/p80211netdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/wlan-ng/p80211netdev.c +1 -1
index 70570e8a5ad2..a02ae9b13ccc 100644
@@ -325,7 +325,7 @@ static netdev_tx_t p80211knetdev_hard_start_xmit(struct sk_buff *skb,
 						 struct net_device *netdev)
 {
 	int result = 0;
-	int txresult = -1;
+	int txresult;
 	struct wlandevice *wlandev = netdev->ml_priv;
 	union p80211_hdr p80211_hdr;
 	struct p80211_metawep p80211_wep;
Signature · 1 line
2.30.2