summaryrefslogtreecommitdiffstats
path: root/Modules/termios.c
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2008-05-26 13:28:38 (GMT)
committerChristian Heimes <christian@cheimes.de>2008-05-26 13:28:38 (GMT)
commit72b710a59617ebe6dd1c41613d2c7eb81702efd9 (patch)
treecd134cc11c49ba09f50e44a9f36b69f2b0ffc893 /Modules/termios.c
parent9c4756ea265b5ebd71c9ae59f3673c7cecb6f060 (diff)
downloadcpython-72b710a59617ebe6dd1c41613d2c7eb81702efd9.zip
cpython-72b710a59617ebe6dd1c41613d2c7eb81702efd9.tar.gz
cpython-72b710a59617ebe6dd1c41613d2c7eb81702efd9.tar.bz2
Renamed PyString to PyBytes
Diffstat (limited to 'Modules/termios.c')
-rw-r--r--Modules/termios.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/Modules/termios.c b/Modules/termios.c
index 0707ad9..ff69c92 100644
--- a/Modules/termios.c
+++ b/Modules/termios.c
@@ -91,7 +91,7 @@ termios_tcgetattr(PyObject *self, PyObject *args)
return NULL;
for (i = 0; i < NCCS; i++) {
ch = (char)mode.c_cc[i];
- v = PyString_FromStringAndSize(&ch, 1);
+ v = PyBytes_FromStringAndSize(&ch, 1);
if (v == NULL)
goto err;
PyList_SetItem(cc, i, v);
@@ -183,8 +183,8 @@ termios_tcsetattr(PyObject *self, PyObject *args)
for (i = 0; i < NCCS; i++) {
v = PyList_GetItem(cc, i);
- if (PyString_Check(v) && PyString_Size(v) == 1)
- mode.c_cc[i] = (cc_t) * PyString_AsString(v);
+ if (PyBytes_Check(v) && PyBytes_Size(v) == 1)
+ mode.c_cc[i] = (cc_t) * PyBytes_AsString(v);
else if (PyLong_Check(v))
mode.c_cc[i] = (cc_t) PyLong_AsLong(v);
else {