MCPcopy Create free account
hub / github.com/PLSysSec/wave / trace_openat

Function trace_openat

src/os/mod.rs:29–38  ·  view source on GitHub ↗

#[ensures(one_effect!(old(trace), trace, effect!(PathAccessAt, os_fd, p)))]

(
    ctx: &VmCtx,
    dir_fd: HostFd,
    path: HostPath,
    flags: i32,
)

Source from the content-addressed store, hash-verified

27#[ensures(trace_safe(trace, ctx))]
28// #[ensures(one_effect!(old(trace), trace, effect!(PathAccessAt, os_fd, p)))]
29pub fn trace_openat(
30 ctx: &VmCtx,
31 dir_fd: HostFd,
32 path: HostPath,
33 flags: i32,
34) -> RuntimeResult<usize> {
35 let os_fd: usize = dir_fd.to_raw();
36 let r = os_openat(os_fd, path, flags, 0o666);
37 RuntimeError::from_syscall_ret(r)
38}
39
40#[with_ghost_var(trace: &mut Trace)]
41#[requires(ctx_safe(ctx))]

Callers 1

wasi_path_openFunction · 0.85

Calls 1

to_rawMethod · 0.80

Tested by

no test coverage detected