summaryrefslogtreecommitdiff
path: root/Modules/pwdmodule.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/pwdmodule.c')
-rw-r--r--Modules/pwdmodule.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/Modules/pwdmodule.c b/Modules/pwdmodule.c
index 4b09312e8a..b7e0c92a87 100644
--- a/Modules/pwdmodule.c
+++ b/Modules/pwdmodule.c
@@ -90,6 +90,7 @@ pwd_getpwnam(self, args)
return mkpwent(p);
}
+#ifdef HAVE_GETPWENT
static PyObject *
pwd_getpwall(self, args)
PyObject *self;
@@ -113,11 +114,14 @@ pwd_getpwall(self, args)
}
return d;
}
+#endif
static PyMethodDef pwd_methods[] = {
{"getpwuid", pwd_getpwuid},
{"getpwnam", pwd_getpwnam},
+#ifdef HAVE_GETPWENT
{"getpwall", pwd_getpwall},
+#endif
{NULL, NULL} /* sentinel */
};