grant_privilege(p1)
public
Show source
/*
* call-seq:
* Process::UID.grant_privilege(integer) => fixnum
* Process::UID.eid= integer => fixnum
*
* Set the effective user ID, and if possible, the saved user ID of
* the process to the given _integer_. Returns the new
* effective user ID. Not available on all platforms.
*
* [Process.uid, Process.euid] #=> [0, 0]
* Process::UID.grant_privilege(31) #=> 31
* [Process.uid, Process.euid] #=> [0, 31]
*/
static VALUE
p_uid_grant_privilege(obj, id)
VALUE obj, id;
{
return rb_seteuid_core(NUM2INT(id));
}