Skip to contentSkip to conversation

exec: Delete unnecessary statements in remove_arg_zero()

PATCH Applied Li kunyu 2 participants 2 messages Feb 20, 2024 – Feb 24, 2024

Subsystems (3)
lore
Share & tools
lore

Li kunyu

author
#0 lore raw

PATCH 1/1 exec: Delete unnecessary statements in remove_arg_zero()

'ret=0; ' In actual operation, the ret was not modified, so this sentence can be removed.

---
 fs/exec.c | 1 -
 1 file changed, 1 deletion(-)
fs/exec.c +0 -1
index 7be0527f5ff25..10309a93d9c52 100644
@@ -1747,7 +1747,6 @@ int remove_arg_zero(struct linux_binprm *bprm)
 
 	bprm->p++;
 	bprm->argc--;
-	ret = 0;
 
 out:
 	return ret;
Signature · 1 line
2.18.2
Applied
#1 lore raw
Quoted 4 lines · Li kunyu

'ret=0; ' In actual operation, the ret was not modified, so this sentence can be removed.

Applied to for-next/execve, thanks!

[1/1] exec: Delete unnecessary statements in remove_arg_zero()

      https://git.kernel.org/kees/c/d3f0d7bbaefd

Take care,

Signature · 1 line
Kees Cook