Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 3170f327 authored by Tina Johnson's avatar Tina Johnson Committed by Greg Kroah-Hartman
Browse files

Staging: media: lirc: lirc_imon: Removed unnecessary variable to simplify return variable handling



Variable rc was removed after merging its assignment statement with
immediately following return statement. Variable retval is not used
at all other that to return its initial value.Hence replaced retval
with its initial value in the return statement and removed the variable.

This patch was done using Coccinelle script and the following semantic
patch was used:

@rule1@
identifier ret;
expression e;
@@

-int ret = 0;
 ... when != ret
(
-ret = e;
+return e;
-return ret;
|
-return ret;
+return 0;
)

Signed-off-by: default avatarTina Johnson <tinajohnson.1234@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 8ad5360a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment