Store context memory information
This commit is contained in:
parent
bed09d0518
commit
bcd318d80b
5 changed files with 131 additions and 59 deletions
|
@ -93,10 +93,7 @@ pub fn exec(path: &[u8], _args: &[[usize; 2]]) -> Result<usize> {
|
|||
let _ = syscall::close(file);
|
||||
|
||||
match elf::Elf::from(&data) {
|
||||
Ok(elf) => {
|
||||
elf.run();
|
||||
Ok(0)
|
||||
},
|
||||
Ok(elf) => elf.run().and(Ok(0)),
|
||||
Err(err) => {
|
||||
println!("failed to execute {}: {}", unsafe { str::from_utf8_unchecked(path) }, err);
|
||||
Err(Error::NoExec)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue