API
 
Loading...
Searching...
No Matches
thSetuid.cpp
Go to the documentation of this file.
1/** \file thSetuid.cpp
2 * \brief Set euid in a single thread
3 * \author Jared R. Males (jaredmales@gmail.com)
4 *
5 * \ingroup sys_files
6 */
7
8#include "thSetuid.hpp"
9
10
11#include <sys/syscall.h>
12
13namespace MagAOX
14{
15namespace sys
16{
17
18int th_seteuid(uid_t euid /**< [in] the desired new effective user id */)
19{
20 int rv = syscall(SYS_setreuid, -1, euid);
21
22 return rv;
23}
24
25
26
27
28} //namespace sys
29} //namespace MagAOX
30
31
int th_seteuid(uid_t euid)
Sets the effective user id of the calling thread, rather than the whole process.
Definition thSetuid.cpp:18
Definition dm.hpp:24
Set euid in a single thread.