staging: rtlwifi: remove memset before memcpy

calling memcpy immediately after memset with the same region of memory
makes memset redundant.

Signed-off-by: Himanshu Jha <himanshujha199640@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Himanshu Jha 2017-08-28 16:15:32 +05:30 committed by Greg Kroah-Hartman
parent 56277035c2
commit 30207d7b64
1 changed files with 0 additions and 1 deletions

View File

@ -2558,7 +2558,6 @@ bool rtl_check_beacon_key(struct ieee80211_hw *hw, void *data, unsigned int len)
if (!cur_bcn_key->valid) {
/* update cur_beacon_keys */
memset(cur_bcn_key, 0, sizeof(bcn_key));
memcpy(cur_bcn_key, &bcn_key, sizeof(bcn_key));
cur_bcn_key->valid = true;