summaryrefslogtreecommitdiffstats
path: root/Modules/pyexpat.c
diff options
context:
space:
mode:
Diffstat (limited to 'Modules/pyexpat.c')
-rw-r--r--Modules/pyexpat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/pyexpat.c b/Modules/pyexpat.c
index 0053201..852d093 100644
--- a/Modules/pyexpat.c
+++ b/Modules/pyexpat.c
@@ -866,8 +866,8 @@ readinst(char *buf, int buf_size, PyObject *meth)
if (PyString_Check(str))
ptr = PyString_AS_STRING(str);
- else if (PyBytes_Check(str))
- ptr = PyBytes_AS_STRING(str);
+ else if (PyByteArray_Check(str))
+ ptr = PyByteArray_AS_STRING(str);
else {
PyErr_Format(PyExc_TypeError,
"read() did not return a bytes object (type=%.400s)",