mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-02-01 17:35:17 +00:00
Add compat function for geteuid()
* configure.ac: Check for geteuid() * src/util/util.h: Compat for geteuid()
This commit is contained in:
parent
2a2a00eb69
commit
bd82db4057
@ -120,7 +120,7 @@ AC_MSG_RESULT([$have_cpuid])
|
||||
dnl Availability of various common functions (non-fatal if missing),
|
||||
dnl and various less common threadsafe functions
|
||||
AC_CHECK_FUNCS_ONCE([cfmakeraw regexec sched_getaffinity getuid getgid \
|
||||
initgroups posix_fallocate mmap kill \
|
||||
geteuid initgroups posix_fallocate mmap kill \
|
||||
getmntent_r getgrnam_r getpwuid_r])
|
||||
|
||||
dnl Availability of pthread functions (if missing, win32 threading is
|
||||
|
@ -269,6 +269,10 @@ const char *virEnumToString(const char *const*types,
|
||||
static inline int getuid (void) { return 0; }
|
||||
# endif
|
||||
|
||||
# ifndef HAVE_GETEUID
|
||||
static inline int geteuid (void) { return 0; }
|
||||
# endif
|
||||
|
||||
# ifndef HAVE_GETGID
|
||||
static inline int getgid (void) { return 0; }
|
||||
# endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user