Skip to content
Commit 5ce91a9e authored by Vaishali Thakkar's avatar Vaishali Thakkar Committed by Greg Kroah-Hartman
Browse files

Staging: lustre: Return statement is moved left after removing else



This patch fixes following checkpatch.pl warning using coccinelle:

WARNING: else is not generally useful after a break or return

Semantic patch used for this is as follows:

@rule1@
expression e1;
@@

        if (e1) { ... return ...; }
-       else{
                ...
-       }

@rule2@
expression e2;
statement s1;
@@

        if(e2) { ... return ...; }
-       else
                s1

Signed-off-by: default avatarVaishali Thakkar <vthakkar1994@gmail.com>
Acked-by: default avatarJulia Lawall <julia.lawall@lip6.fr>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 26c4ea46
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment