devela::_dep::nc::call

Function getpgid

pub unsafe fn getpgid(pid: i32) -> Result<i32, i32> 
Available on crate feature dep_nc only.
Expand description

Returns the PGID(process group ID) of the process specified by pid.

§Examples

let ppid = unsafe { nc::getppid() };
let pgid = unsafe { nc::getpgid(ppid) };
assert!(pgid.is_ok());