MCPcopy Index your code
hub / github.com/RustPython/RustPython / setgroups

Function setgroups

crates/vm/src/stdlib/posix.rs:1627–1633  ·  view source on GitHub ↗
(
        group_ids: crate::function::ArgIterable<Gid>,
        vm: &VirtualMachine,
    )

Source from the content-addressed store, hash-verified

1625 #[cfg(not(any(target_os = "ios", target_os = "macos", target_os = "redox")))]
1626 #[pyfunction]
1627 fn setgroups(
1628 group_ids: crate::function::ArgIterable<Gid>,
1629 vm: &VirtualMachine,
1630 ) -> PyResult<()> {
1631 let gids = group_ids.iter(vm)?.collect::<Result<Vec<_>, _>>()?;
1632 unistd::setgroups(&gids).map_err(|err| err.into_pyexception(vm))
1633 }
1634
1635 #[cfg(any(target_os = "linux", target_os = "freebsd", target_os = "macos"))]
1636 fn envp_from_dict(

Callers 1

exec_innerFunction · 0.85

Calls 2

iterMethod · 0.45
into_pyexceptionMethod · 0.45

Tested by

no test coverage detected