]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
staging: rtl8188eu: core: rtw_mlme: Remove return variables.
authorSanjana Sanikommu <sanjana99reddy99@gmail.com>
Thu, 21 Mar 2019 07:54:04 +0000 (13:24 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 21 Mar 2019 19:01:42 +0000 (20:01 +0100)
The last two lines in the function could
be compressed into one. Avoid usage of local variable.
Issue found with Coccinelle using ret.cocci.

Signed-off-by: Sanjana Sanikommu <sanjana99reddy99@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8188eu/core/rtw_mlme.c

index 2b5aaa940957acd9295b4db5f2ec46401a50f931..9a4aad5ec36555500023e3727e7878c8fa3deb84 100644 (file)
@@ -1632,8 +1632,7 @@ int rtw_set_key(struct adapter *adapter, struct security_priv *psecuritypriv, in
        pcmd->rsp = NULL;
        pcmd->rspsz = 0;
        INIT_LIST_HEAD(&pcmd->list);
-       res = rtw_enqueue_cmd(pcmdpriv, pcmd);
-       return res;
+       return rtw_enqueue_cmd(pcmdpriv, pcmd);
 
 err_free_parm:
        kfree(psetkeyparm);