qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [COMMIT e99a22c] Avoid collision with system NGROUPS defi


From: Anthony Liguori
Subject: [Qemu-commits] [COMMIT e99a22c] Avoid collision with system NGROUPS definition
Date: Sat, 13 Jun 2009 15:13:31 -0000

From: Blue Swirl <address@hidden>

Signed-off-by: Blue Swirl <address@hidden>

diff --git a/bsd-user/bsdload.c b/bsd-user/bsdload.c
index 3c3a047..05fd20a 100644
--- a/bsd-user/bsdload.c
+++ b/bsd-user/bsdload.c
@@ -10,7 +10,7 @@
 
 #include "qemu.h"
 
-#define NGROUPS 32
+#define TARGET_NGROUPS 32
 
 /* ??? This should really be somewhere else.  */
 abi_long memcpy_to_target(abi_ulong dest, const void *src,
@@ -31,9 +31,9 @@ static int in_group_p(gid_t g)
     /* return TRUE if we're in the specified group, FALSE otherwise */
     int         ngroup;
     int         i;
-    gid_t       grouplist[NGROUPS];
+    gid_t       grouplist[TARGET_NGROUPS];
 
-    ngroup = getgroups(NGROUPS, grouplist);
+    ngroup = getgroups(TARGET_NGROUPS, grouplist);
     for(i = 0; i < ngroup; i++) {
         if(grouplist[i] == g) {
             return 1;




reply via email to

[Prev in Thread] Current Thread [Next in Thread]