lkml.org 
[lkml]   [2006]   [Mar]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[2.6 patch] ieee80211_wx.c: remove dead code
Since sec->key_sizes[] is an u8, len can't be < 0.

Spotted by the Coverity checker.


Signed-off-by: Adrian Bunk <bunk@stusta.de>

--- linux-2.6.16-rc6-mm1-full/net/ieee80211/ieee80211_wx.c.old 2006-03-14 03:01:43.000000000 +0100
+++ linux-2.6.16-rc6-mm1-full/net/ieee80211/ieee80211_wx.c 2006-03-14 03:02:02.000000000 +0100
@@ -505,7 +505,7 @@ int ieee80211_wx_get_encode(struct ieee8
len = sec->key_sizes[key];
memcpy(keybuf, sec->keys[key], len);

- erq->length = (len >= 0 ? len : 0);
+ erq->length = len;
erq->flags |= IW_ENCODE_ENABLED;

if (ieee->open_wep)
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-03-15 17:42    [W:0.031 / U:0.156 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site