native_setregid function

void native_setregid(
  1. int rgid,
  2. int egid
)

Set the real group ID of the calling process to RGID, and the effective group ID of the calling process to EGID. Throws PosixException if the operation fails.

Implementation

void native_setregid(
  int rgid,
  int egid,
) {
  _setregid ??= Libc().dylib.lookupFunction<
      ffi.Int32 Function(ffi.Uint32, ffi.Uint32), _dart_setregid>('setregid');
  final result = _setregid!(
    rgid,
    egid,
  );

  _throwIfErrno('setregid', result);
}