[Zope-Checkins] CVS: Zope/lib/Components/initgroups - initgroups.c:1.2
Matt Behrens
matt@zigg.com
Thu, 28 Mar 2002 09:15:03 -0500
Update of /cvs-repository/Zope/lib/Components/initgroups
In directory cvs.zope.org:/tmp/cvs-serv21327/lib/Components/initgroups
Modified Files:
initgroups.c
Log Message:
make initgroups module a stub on non-UNIX system, should fix the
Win32 build
=== Zope/lib/Components/initgroups/initgroups.c 1.1 => 1.2 ===
#include "Python.h"
+#if defined(__unix__) || defined(unix)
+
#include <grp.h>
#include <sys/types.h>
#include <unistd.h>
@@ -39,6 +41,16 @@
{"initgroups", initgroups_initgroups, METH_VARARGS},
{NULL, NULL}
};
+
+#else
+
+/* This module is empty on non-UNIX systems. */
+
+static PyMethodDef InitgroupsMethods[] = {
+ {NULL, NULL}
+};
+
+#endif /* defined(__unix__) || defined(unix) */
void
initinitgroups()