diff options
author | obrien <obrien@FreeBSD.org> | 2001-03-04 11:58:50 +0000 |
---|---|---|
committer | obrien <obrien@FreeBSD.org> | 2001-03-04 11:58:50 +0000 |
commit | 1814a78315f96963872a0205d8c213b13980d99a (patch) | |
tree | aef3649247acf14fd658b4eb6b51f3bd6f5ae3f5 /sys/kern/imgact_elf.c | |
parent | 8428d214ad83c8ac0eef43ee6237f8773b800cb3 (diff) | |
download | FreeBSD-src-1814a78315f96963872a0205d8c213b13980d99a.zip FreeBSD-src-1814a78315f96963872a0205d8c213b13980d99a.tar.gz |
Do not set a default ELF syscall ABI fallback.
If one runs an un-branded Linux static binary that calls Linux's fcntl
the machine will reboot when interupted by the FreeBSD syscall ABI.
Diffstat (limited to 'sys/kern/imgact_elf.c')
-rw-r--r-- | sys/kern/imgact_elf.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/sys/kern/imgact_elf.c b/sys/kern/imgact_elf.c index 553ef75..f35f864 100644 --- a/sys/kern/imgact_elf.c +++ b/sys/kern/imgact_elf.c @@ -438,9 +438,12 @@ fail: return error; } -static int fallback_elf_brand = ELFOSABI_FREEBSD; +/* + * non static, as it can be overridden by start_init() + */ +int fallback_elf_brand = -1; SYSCTL_INT(_kern, OID_AUTO, fallback_elf_brand, CTLFLAG_RW, - &fallback_elf_brand, ELFOSABI_FREEBSD, + &fallback_elf_brand, -1, "ELF brand of last resort"); static int @@ -612,10 +615,6 @@ exec_elf_imgact(struct image_params *imgp) } } - /* XXX - Assume FreeBSD after the branding method change. */ - if (brand_info == NULL) - brand_info = &freebsd_brand_info; - if (brand_info == NULL) { uprintf("ELF binary type \"%u\" not known.\n", hdr->e_ident[EI_OSABI]); |