MCPcopy Create free account
hub / github.com/bytecodealliance/rustix / set_secure_computing_mode

Function set_secure_computing_mode

src/thread/prctl.rs:173–175  ·  view source on GitHub ↗
(mode: SecureComputingMode)

Source from the content-addressed store, hash-verified

171/// [`prctl(PR_SET_SECCOMP,…)`]: https://man7.org/linux/man-pages/man2/prctl.2.html
172#[inline]
173pub fn set_secure_computing_mode(mode: SecureComputingMode) -> io::Result<()> {
174 unsafe { prctl_2args(PR_SET_SECCOMP, mode as usize as *mut _) }.map(|_r| ())
175}
176
177//
178// PR_CAPBSET_READ/PR_CAPBSET_DROP

Callers

nothing calls this directly

Calls 1

prctl_2argsFunction · 0.85

Tested by

no test coverage detected