Commit b924a819 authored by Jason Yan's avatar Jason Yan Committed by Kees Cook

gcc-plugins: structleak: remove unneeded variable 'ret'

Fix the following coccicheck warning:

scripts/gcc-plugins/structleak_plugin.c:177:14-17: Unneeded variable:
"ret". Return "0" on line 207
Reported-by: default avatarHulk Robot <hulkci@huawei.com>
Signed-off-by: default avatarJason Yan <yanaijie@huawei.com>
Signed-off-by: default avatarKees Cook <keescook@chromium.org>
Link: https://lore.kernel.org/r/20200418070505.10715-1-yanaijie@huawei.com
parent fe07bfda
...@@ -170,7 +170,6 @@ static void initialize(tree var) ...@@ -170,7 +170,6 @@ static void initialize(tree var)
static unsigned int structleak_execute(void) static unsigned int structleak_execute(void)
{ {
basic_block bb; basic_block bb;
unsigned int ret = 0;
tree var; tree var;
unsigned int i; unsigned int i;
...@@ -200,7 +199,7 @@ static unsigned int structleak_execute(void) ...@@ -200,7 +199,7 @@ static unsigned int structleak_execute(void)
initialize(var); initialize(var);
} }
return ret; return 0;
} }
#define PASS_NAME structleak #define PASS_NAME structleak
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment