staging: dgnc: delete successive assignments to the same location
Successive assignments to the same location is meaningless and can be deleted. The Coccinelle semantic patch was used to find cases. @@ expression e1,e2,e3; @@ ( (<+...e1++...+>)=e2; | (<+...e1--...+>)=e2; | (<+...++e1...+>)=e2; | (<+...--e1...+>)=e2; | e1=e2; e1 = <+...e1...+>; | *e1=e2; *e1=e3; ) Signed-off-by: Jiayi Ye <yejiayily@gmail.com> Reviewed-by: Josh Triplett <josh@joshtriplett.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Родитель
f474f5e535
Коммит
308c32f9e8
|
@ -2205,8 +2205,6 @@ static int dgnc_set_modem_info(struct tty_struct *tty, unsigned int command, uns
|
|||
if (!bd || bd->magic != DGNC_BOARD_MAGIC)
|
||||
return ret;
|
||||
|
||||
ret = 0;
|
||||
|
||||
ret = get_user(arg, value);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
|
Загрузка…
Ссылка в новой задаче