summaryrefslogtreecommitdiff
path: root/fs/exec.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <greg@kroah.com>2002-11-26 23:11:25 -0800
committerGreg Kroah-Hartman <greg@kroah.com>2002-11-26 23:11:25 -0800
commitee0990090dc3e324f878acc86eee8edabf147ec7 (patch)
tree44b0274f2b2adbcafd28eb03c6c8269fe1cb6be9 /fs/exec.c
parent2e1dab7d3c33534fc1805867322c22d26c87e609 (diff)
LSM: change if statements into something more readable for the fs/* files.
Diffstat (limited to 'fs/exec.c')
-rw-r--r--fs/exec.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/fs/exec.c b/fs/exec.c
index 3757201478c3..a0a4aa824ae6 100644
--- a/fs/exec.c
+++ b/fs/exec.c
@@ -841,7 +841,8 @@ int prepare_binprm(struct linux_binprm *bprm)
}
/* fill in binprm security blob */
- if ((retval = security_bprm_set(bprm)))
+ retval = security_bprm_set(bprm);
+ if (retval)
return retval;
memset(bprm->buf,0,BINPRM_BUF_SIZE);
@@ -958,7 +959,8 @@ int search_binary_handler(struct linux_binprm *bprm,struct pt_regs *regs)
}
}
#endif
- if ((retval = security_bprm_check(bprm)))
+ retval = security_bprm_check(bprm);
+ if (retval)
return retval;
/* kernel module loader fixup */
@@ -1054,7 +1056,8 @@ int do_execve(char * filename, char ** argv, char ** envp, struct pt_regs * regs
if ((retval = bprm.envc) < 0)
goto out_mm;
- if ((retval = security_bprm_alloc(&bprm)))
+ retval = security_bprm_alloc(&bprm);
+ if (retval)
goto out;
retval = prepare_binprm(&bprm);