Function libseccomp::set_api
source · [−]pub fn set_api(level: u32) -> Result<(), SeccompError>
Expand description
Sets the API level forcibly.
General use of this function is strongly discouraged.
See the seccomp_api_get(3)
man page for details on available API levels.
This function corresponds to
seccomp_api_set
.
Arguments
level
- The API level
Errors
If the API level can not be detected due to the library being older than v2.4.0, an error will be returned.
Examples
set_api(1)?;