summaryrefslogtreecommitdiffstats
path: root/drivers/staging/vt6655/iwctl.c
diff options
context:
space:
mode:
authorJulia Lawall2010-03-09 22:15:21 +0100
committerGreg Kroah-Hartman2010-05-11 20:35:34 +0200
commit8f18604e6f0975fa852f43f90d5556efd67efadc (patch)
treef36ae2b6163467d3448e298c8edd2435fd4a69bd /drivers/staging/vt6655/iwctl.c
parentStaging: rt2860: fixed coding-style issues in pci_main_dev.c (diff)
downloadkernel-qcow2-linux-8f18604e6f0975fa852f43f90d5556efd67efadc.tar.gz
kernel-qcow2-linux-8f18604e6f0975fa852f43f90d5556efd67efadc.tar.xz
kernel-qcow2-linux-8f18604e6f0975fa852f43f90d5556efd67efadc.zip
Staging: drop redundant memset
The region set by the call to memset is immediately overwritten by the subsequent call to memcpy. The semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ expression e1,e2,e3,e4; @@ - memset(e1,e2,e3); memcpy(e1,e4,e3); // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/vt6655/iwctl.c')
-rw-r--r--drivers/staging/vt6655/iwctl.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/staging/vt6655/iwctl.c b/drivers/staging/vt6655/iwctl.c
index 78b49830a255..824466d5a659 100644
--- a/drivers/staging/vt6655/iwctl.c
+++ b/drivers/staging/vt6655/iwctl.c
@@ -699,7 +699,6 @@ if (pMgmt->eScanState == WMAC_IS_SCANNING) {
if (wrq->sa_family != ARPHRD_ETHER)
rc = -EINVAL;
else {
- memset(pMgmt->abyDesireBSSID, 0xFF, 6);
memcpy(pMgmt->abyDesireBSSID, wrq->sa_data, 6);
//2008-0409-05, <Add> by Einsn Liu
if((pDevice->bLinkPass == TRUE) &&
@@ -889,7 +888,6 @@ if (pMgmt->eScanState == WMAC_IS_SCANNING) {
BYTE abyTmpDesireSSID[WLAN_IEHDR_LEN + WLAN_SSID_MAXLEN + 1];
UINT ii , uSameBssidNum=0;
- memset(abyTmpDesireSSID,0,sizeof(abyTmpDesireSSID));
memcpy(abyTmpDesireSSID,pMgmt->abyDesireSSID,sizeof(abyTmpDesireSSID));
pCurr = BSSpSearchBSSList(pDevice,
NULL,