[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH v2 27/48] bsd-user: style tweak: space pedantry
From: |
imp |
Subject: |
[PATCH v2 27/48] bsd-user: style tweak: space pedantry |
Date: |
Sat, 24 Apr 2021 09:59:55 -0600 |
From: Warner Losh <imp@bsdimp.com>
Signed-off-by: Warner Losh <imp@bsdimp.com>
---
bsd-user/elfload.c | 22 +++++++++++-----------
1 file changed, 11 insertions(+), 11 deletions(-)
diff --git a/bsd-user/elfload.c b/bsd-user/elfload.c
index 243a5a5048..f455a3812a 100644
--- a/bsd-user/elfload.c
+++ b/bsd-user/elfload.c
@@ -756,7 +756,7 @@ static void padzero(abi_ulong elf_bss, abi_ulong last_bss)
static abi_ulong create_elf_tables(abi_ulong p, int argc, int envc,
- struct elfhdr * exec,
+ struct elfhdr *exec,
abi_ulong load_addr,
abi_ulong load_bias,
abi_ulong interp_load_addr, int ibcs,
@@ -891,12 +891,12 @@ static abi_ulong load_elf_interp(struct elfhdr
*interp_elf_ex,
if (retval < 0) {
perror("load_elf_interp");
exit(-1);
- free (elf_phdata);
+ free(elf_phdata);
return retval;
}
#ifdef BSWAP_NEEDED
eppnt = elf_phdata;
- for (i = 0; i<interp_elf_ex->e_phnum; i++, eppnt++) {
+ for (i = 0; i < interp_elf_ex->e_phnum; i++, eppnt++) {
bswap_phdr(eppnt);
}
#endif
@@ -1155,11 +1155,11 @@ int load_elf_binary(struct linux_binprm *bprm, struct
target_pt_regs *regs,
unsigned int interpreter_type = INTERPRETER_NONE;
unsigned char ibcs2_interpreter;
int i;
- struct elf_phdr * elf_ppnt;
+ struct elf_phdr *elf_ppnt;
struct elf_phdr *elf_phdata;
abi_ulong elf_bss, k, elf_brk;
int retval;
- char * elf_interpreter;
+ char *elf_interpreter;
abi_ulong elf_entry, interp_load_addr = 0;
abi_ulong start_code, end_code, start_data, end_data;
abi_ulong reloc_func_desc = 0;
@@ -1183,14 +1183,14 @@ int load_elf_binary(struct linux_binprm *bprm, struct
target_pt_regs *regs,
}
bprm->p = copy_elf_strings(1, &bprm->filename, bprm->page, bprm->p);
- bprm->p = copy_elf_strings(bprm->envc, bprm->envp, bprm->page,bprm->p);
- bprm->p = copy_elf_strings(bprm->argc, bprm->argv, bprm->page,bprm->p);
+ bprm->p = copy_elf_strings(bprm->envc, bprm->envp, bprm->page, bprm->p);
+ bprm->p = copy_elf_strings(bprm->argc, bprm->argv, bprm->page, bprm->p);
if (!bprm->p) {
retval = -E2BIG;
}
/* Now read in all of the header information */
- elf_phdata = (struct elf_phdr *)malloc(elf_ex.e_phentsize*elf_ex.e_phnum);
+ elf_phdata = (struct elf_phdr *)malloc(elf_ex.e_phentsize *
elf_ex.e_phnum);
if (elf_phdata == NULL) {
return -ENOMEM;
}
@@ -1223,11 +1223,11 @@ int load_elf_binary(struct linux_binprm *bprm, struct
target_pt_regs *regs,
elf_interpreter = NULL;
start_code = ~((abi_ulong)0UL);
end_code = 0;
- start_data = 0;
+ start_data =n 0;
end_data = 0;
interp_ex.a_info = 0;
- for (i = 0;i < elf_ex.e_phnum; i++) {
+ for (i = 0; i < elf_ex.e_phnum; i++) {
if (elf_ppnt->p_type == PT_INTERP) {
if (elf_interpreter != NULL)
{
@@ -1267,7 +1267,7 @@ int load_elf_binary(struct linux_binprm *bprm, struct
target_pt_regs *regs,
if (strcmp(elf_interpreter, "/usr/lib/libc.so.1") == 0 ||
strcmp(elf_interpreter, "/usr/lib/ld.so.1") == 0) {
- ibcs2_interpreter = 1;
+ ibcs2_interpreter = 1;
}
if (retval >= 0) {
--
2.22.1
- Re: [PATCH v2 26/48] bsd-user: move sparc cpu_loop into target_arch_cpu.h as target_cpu_loop, (continued)
- [PATCH v2 42/48] bsd-user: style tweak: spaces around operators and commas, imp, 2021/04/24
- [PATCH v2 38/48] bsd-user: style tweak: use {} for all if statements, format else correctly, imp, 2021/04/24
- [PATCH v2 44/48] bsd-user: style tweak: use preferred block comments, imp, 2021/04/24
- [PATCH v2 48/48] bsd-user: put back a break; that had gone missing..., imp, 2021/04/24
- [PATCH v2 19/48] bsd-user: style tweak: move extern to header file, imp, 2021/04/24
- [PATCH v2 27/48] bsd-user: style tweak: space pedantry,
imp <=
- [PATCH v2 35/48] bsd-user: style tweak: use {} for all if statements, format else correctly, imp, 2021/04/24
- [PATCH v2 30/48] bsd-user: style tweak: fix block comments, imp, 2021/04/24
- [PATCH v2 36/48] bsd-user: style tweak: Use preferred block comments, imp, 2021/04/24
- [PATCH v2 46/48] bsd-user: style tweak: Return is not a function call., imp, 2021/04/24
- [PATCH v2 34/48] bsd-user: style tweak: don't assign in if statements, imp, 2021/04/24