summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBhaktipriya Shridhar <bhaktipriya96@gmail.com>2016-02-23 21:27:57 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-03-12 06:09:09 (GMT)
commitf705a2dddd206b31ff7731b3adc69a2433ca6d00 (patch)
tree57cabba959b3b8536eddc1a2ab80e667e4208ce4
parentb1b20e7155de612f065dbc0cda53186605fa944c (diff)
downloadlinux-f705a2dddd206b31ff7731b3adc69a2433ca6d00.tar.xz
staging: rtl8192u: ieee802111: Drop Useless Initialization
Removed initialisation of a varible if it is immediately reassigned. Changes were made using Coccinelle. @bad@ identifier i; position p; @@ i =@p <+...i...+>; @@ type T; constant C; expression e; identifier i; position p != bad.p; @@ T i - = C ; i =@p e; Signed-off-by: Bhaktipriya Shridhar <bhaktipriya96@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c b/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c
index 789b7c9..28737ec 100644
--- a/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c
+++ b/drivers/staging/rtl8192u/ieee80211/rtl819x_BAProc.c
@@ -254,7 +254,7 @@ static struct sk_buff *ieee80211_DELBA(
static void ieee80211_send_ADDBAReq(struct ieee80211_device *ieee,
u8 *dst, PBA_RECORD pBA)
{
- struct sk_buff *skb = NULL;
+ struct sk_buff *skb;
skb = ieee80211_ADDBA(ieee, dst, pBA, 0, ACT_ADDBAREQ); //construct ACT_ADDBAREQ frames so set statuscode zero.
if (skb)
@@ -282,7 +282,7 @@ static void ieee80211_send_ADDBAReq(struct ieee80211_device *ieee,
static void ieee80211_send_ADDBARsp(struct ieee80211_device *ieee, u8 *dst,
PBA_RECORD pBA, u16 StatusCode)
{
- struct sk_buff *skb = NULL;
+ struct sk_buff *skb;
skb = ieee80211_ADDBA(ieee, dst, pBA, StatusCode, ACT_ADDBARSP); //construct ACT_ADDBARSP frames
if (skb)
{
@@ -311,7 +311,7 @@ static void ieee80211_send_DELBA(struct ieee80211_device *ieee, u8 *dst,
PBA_RECORD pBA, TR_SELECT TxRxSelect,
u16 ReasonCode)
{
- struct sk_buff *skb = NULL;
+ struct sk_buff *skb;
skb = ieee80211_DELBA(ieee, dst, pBA, TxRxSelect, ReasonCode); //construct ACT_ADDBARSP frames
if (skb)
{