File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
src/uucore/src/lib/features Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 55
66// spell-checker:ignore (vars) cvar exitstatus cmdline kworker getsid getpid
77// spell-checker:ignore (sys/unix) WIFSIGNALED ESRCH
8- // spell-checker:ignore pgrep pwait snice
8+ // spell-checker:ignore pgrep pwait snice getpgrp
99
1010use libc:: { gid_t, pid_t, uid_t} ;
1111#[ cfg( not( target_os = "redox" ) ) ]
@@ -23,6 +23,12 @@ pub fn geteuid() -> uid_t {
2323 unsafe { libc:: geteuid ( ) }
2424}
2525
26+ /// `getpgrp()` returns the process group ID of the calling process.
27+ /// It is a trivial wrapper over libc::getpgrp to "hide" the unsafe
28+ pub fn getpgrp ( ) -> pid_t {
29+ unsafe { libc:: getpgrp ( ) }
30+ }
31+
2632/// `getegid()` returns the effective group ID of the calling process.
2733pub fn getegid ( ) -> gid_t {
2834 unsafe { libc:: getegid ( ) }
You can’t perform that action at this time.
0 commit comments