setreuid function

void setreuid(
  1. int ruid,
  2. int euid
)

Set the real user ID of the calling process to RUID, and the effective user ID of the calling process to EUID. Throws PosixException if the operation fails.

Implementation

void setreuid(
  int ruid,
  int euid,
) {
  _setreuid ??= Libc().dylib.lookupFunction<
      ffi.Int32 Function(ffi.Uint32, ffi.Uint32), _dart_setreuid>('setreuid');
  final result = _setreuid!(
    ruid,
    euid,
  );

  _throwIfError('setreuid', result);
}