summaryrefslogtreecommitdiffstats
path: root/Modules/grpmodule.c
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2008-05-26 12:51:38 (GMT)
committerChristian Heimes <christian@cheimes.de>2008-05-26 12:51:38 (GMT)
commit593daf545bd9b7e7bcb27b498ecc6f36db9ae395 (patch)
treec0a57029b9ab0eb18a2bb4f8fd65f0817f1a1707 /Modules/grpmodule.c
parentc3cb683d638e9d660c18a05293a576f98965166e (diff)
downloadcpython-593daf545bd9b7e7bcb27b498ecc6f36db9ae395.zip
cpython-593daf545bd9b7e7bcb27b498ecc6f36db9ae395.tar.gz
cpython-593daf545bd9b7e7bcb27b498ecc6f36db9ae395.tar.bz2
Renamed PyString to PyBytes
Diffstat (limited to 'Modules/grpmodule.c')
-rw-r--r--Modules/grpmodule.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Modules/grpmodule.c b/Modules/grpmodule.c
index e5b9f47..74bf0dc 100644
--- a/Modules/grpmodule.c
+++ b/Modules/grpmodule.c
@@ -47,7 +47,7 @@ mkgrent(struct group *p)
return NULL;
}
for (member = p->gr_mem; *member != NULL; member++) {
- PyObject *x = PyString_FromString(*member);
+ PyObject *x = PyBytes_FromString(*member);
if (x == NULL || PyList_Append(w, x) != 0) {
Py_XDECREF(x);
Py_DECREF(w);
@@ -58,13 +58,13 @@ mkgrent(struct group *p)
}
#define SET(i,val) PyStructSequence_SET_ITEM(v, i, val)
- SET(setIndex++, PyString_FromString(p->gr_name));
+ SET(setIndex++, PyBytes_FromString(p->gr_name));
#ifdef __VMS
SET(setIndex++, Py_None);
Py_INCREF(Py_None);
#else
if (p->gr_passwd)
- SET(setIndex++, PyString_FromString(p->gr_passwd));
+ SET(setIndex++, PyBytes_FromString(p->gr_passwd));
else {
SET(setIndex++, Py_None);
Py_INCREF(Py_None);
@@ -113,7 +113,7 @@ grp_getgrnam(PyObject *self, PyObject *pyo_name)
py_str_name = PyObject_Str(pyo_name);
if (!py_str_name)
return NULL;
- name = PyString_AS_STRING(py_str_name);
+ name = PyBytes_AS_STRING(py_str_name);
if ((p = getgrnam(name)) == NULL) {
PyErr_Format(PyExc_KeyError, "getgrnam(): name not found: %s", name);