staging: speakup: compress return logic into one line
Simplify function return by merging assignment and return into one command line. Remove (now) unused local variable. Found using Coccinelle: @@ expression e, ret; @@ -ret = +return e; -return ret; Signed-off-by: Alison Schofield <amsfield22@gmail.com> Acked-by: Julia Lawall <julia.lawall@lip6.fr> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
b3d0ea8d80
commit
5a41b93476
|
@ -393,10 +393,7 @@ static const int num_groups = ARRAY_SIZE(all_groups);
|
|||
|
||||
char *spk_msg_get(enum msg_index_t index)
|
||||
{
|
||||
char *ch;
|
||||
|
||||
ch = speakup_msgs[index];
|
||||
return ch;
|
||||
return speakup_msgs[index];
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue