8e053ee7cb
enhancements: - Simple command-line tools to interface with VMware host - Guest OS scripts that can be triggered by the VMware host - Startup script When compiled with X11 support (the default), this release also provides: - GTK+-based GUI to configure time sync, device connections, and scripts - Helper application to interface with the xf86-video-vmware driver, enabling dynamic screen resize
37 lines
1 KiB
Text
37 lines
1 KiB
Text
$NetBSD: patch-au,v 1.2 2008/08/31 06:36:48 scottr Exp $
|
|
|
|
--- lib/include/su.h.orig 2008-08-08 02:01:52.000000000 -0500
|
|
+++ lib/include/su.h
|
|
@@ -51,7 +51,7 @@ Bool Id_AuthSet(void const *buf, size_t
|
|
Bool Id_AuthCheck(char const *right,
|
|
char const *localizedDescription);
|
|
|
|
-#elif (defined(__linux__) || defined(sun) || defined(__FreeBSD__)) && !defined(N_PLAT_NLM)
|
|
+#elif (defined(__linux__) || defined(sun) || defined(__FreeBSD__) || defined(__NetBSD__)) && !defined(N_PLAT_NLM)
|
|
|
|
#include <sys/types.h>
|
|
#include <unistd.h>
|
|
@@ -87,7 +87,11 @@ int Id_SetRESGid(gid_t rgid, gid_t egid,
|
|
static INLINE int
|
|
Id_SetEUid(uid_t euid)
|
|
{
|
|
+#if defined(__NetBSD__)
|
|
+ return seteuid(euid);
|
|
+#else
|
|
return Id_SetRESUid((uid_t)-1, euid, (uid_t)-1);
|
|
+#endif
|
|
}
|
|
|
|
|
|
@@ -111,7 +115,11 @@ Id_SetEUid(uid_t euid)
|
|
static INLINE int
|
|
Id_SetEGid(gid_t egid)
|
|
{
|
|
+#if defined(__NetBSD__)
|
|
+ return setegid(egid);
|
|
+#else
|
|
return Id_SetRESGid((gid_t)-1, egid, (gid_t)-1);
|
|
+#endif
|
|
}
|
|
|
|
#define IsSuperUser() (0 == geteuid())
|