redox-rt: Remove unnecessary image_file field from FexecResult::Interp

This commit is contained in:
bjorn3
2025-12-09 22:22:09 +01:00
parent 44512df6a3
commit dc77995b57
2 changed files with 0 additions and 5 deletions
-2
View File
@@ -38,7 +38,6 @@ use syscall::{
pub enum FexecResult {
Interp {
path: Box<[u8]>,
image_file: FdGuardUpper,
interp_override: InterpOverride,
},
}
@@ -135,7 +134,6 @@ pub fn fexec_impl(
return Ok(FexecResult::Interp {
path: interp.into_boxed_slice(),
image_file,
interp_override: InterpOverride {
at_entry: header.e_entry as usize,
at_phnum: phnum,
-3
View File
@@ -30,7 +30,6 @@ fn fexec_impl(
interp_override: Option<InterpOverride>,
) -> Result<Infallible> {
let FexecResult::Interp {
image_file,
path,
interp_override: new_interp_override,
} = redox_rt::proc::fexec_impl(
@@ -44,8 +43,6 @@ fn fexec_impl(
interp_override,
)?;
drop(image_file);
// According to elf(5), PT_INTERP requires that the interpreter path be
// null-terminated. Violating this should therefore give the "format error" ENOEXEC.
let path_cstr = CStr::from_bytes_with_nul(&path).map_err(|_| Error::new(ENOEXEC))?;