diff options
author | kib <kib@FreeBSD.org> | 2016-01-09 00:34:48 +0000 |
---|---|---|
committer | kib <kib@FreeBSD.org> | 2016-01-09 00:34:48 +0000 |
commit | 44e96d0cbba625d8bb30d713d573684dbbd6a24f (patch) | |
tree | 06f5f47b84e8efcfece467c0f413102b62e4bcdc /sys/kern/imgact_elf.c | |
parent | 1acda3f94cb4a2bcb6fba7c1a5707786bd6c724b (diff) | |
download | FreeBSD-src-44e96d0cbba625d8bb30d713d573684dbbd6a24f.zip FreeBSD-src-44e96d0cbba625d8bb30d713d573684dbbd6a24f.tar.gz |
MFC r292749:
Do not substitute interpeter if the brand interpreter path is
different from the interpreter path requested by the binary.
Diffstat (limited to 'sys/kern/imgact_elf.c')
-rw-r--r-- | sys/kern/imgact_elf.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/kern/imgact_elf.c b/sys/kern/imgact_elf.c index 584b5da..05f3a43 100644 --- a/sys/kern/imgact_elf.c +++ b/sys/kern/imgact_elf.c @@ -986,7 +986,9 @@ __CONCAT(exec_, __elfN(imgact))(struct image_params *imgp) if (error == 0) have_interp = TRUE; } - if (!have_interp && newinterp != NULL) { + if (!have_interp && newinterp != NULL && + (brand_info->interp_path == NULL || + strcmp(interp, brand_info->interp_path) == 0)) { error = __elfN(load_file)(imgp->proc, newinterp, &addr, &imgp->entry_addr, sv->sv_pagesize); if (error == 0) |