[<prev] [next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.10.1408061213340.2349@hadrien>
Date: Wed, 6 Aug 2014 12:18:14 +0200 (CEST)
From: Julia Lawall <julia.lawall@...6.fr>
To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org
cc: Joe Perches <joe@...ches.com>
Subject: staging/rtl8192[eu]
Hello,
Is anyone actually interested in the files:
drivers/staging/rtl8192e/rtllib_softmac.c
drivers/staging/rtl8192u/ieee80211/ieee80211_softmac.c
Both contain the following code:
if (param->u.wpa_ie.len > MAX_WPA_IE_LEN ||
(param->u.wpa_ie.len && param->u.wpa_ie.data == NULL))
return -EINVAL;
and
if (param->u.crypt.alg != NULL) {
memcpy(sec.keys[param->u.crypt.idx],
param->u.crypt.key,
param->u.crypt.key_len);
In each case, the NULL test has a trivial result, because the requested
field is an array inlined within a structure. In the first case, the
array has size 0, so I guess the intent is to see whether some more space
has been allocated, and in the second case the array contains a string, so
I guess the intent is to see whether something has been stored in the
string. But I don't know how it is intended to do either operation.
julia
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists