Provide information about the runtime information recorded by QEMU
This commit is contained in:
parent
d85fc2487a
commit
af1cecbd98
@ -24,6 +24,7 @@ use fuzz_runner::nyx::aux_buffer::{NYX_SUCCESS, NYX_CRASH, NYX_TIMEOUT, NYX_INPU
|
||||
use libc::fcntl;
|
||||
|
||||
use std::fmt;
|
||||
use std::time::Duration;
|
||||
|
||||
pub mod ffi;
|
||||
|
||||
@ -356,6 +357,11 @@ impl NyxProcess {
|
||||
let len = self.process.aux_buffer().misc.len;
|
||||
String::from_utf8_lossy(&self.process.aux_buffer().misc_data_slice()[0..len as usize]).to_string()
|
||||
}
|
||||
|
||||
pub fn aux_result_duration(&self) -> Duration {
|
||||
let result = &*self.process.aux_buffer().result;
|
||||
Duration::new(result.runtime_sec.into(), result.runtime_usec * 1000)
|
||||
}
|
||||
|
||||
pub fn exec(&mut self) -> NyxReturnValue {
|
||||
match self.process.send_payload(){
|
||||
|
Loading…
x
Reference in New Issue
Block a user