diff options
author | Christian Heimes <christian@cheimes.de> | 2008-05-26 13:22:05 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2008-05-26 13:22:05 (GMT) |
commit | 9c4756ea265b5ebd71c9ae59f3673c7cecb6f060 (patch) | |
tree | 642b21e774a9cb2d949e10ce65e7d10326c70138 /Modules/_ctypes | |
parent | 96d02f3c1e145821cd5ce8817d4263e7d8d57e4a (diff) | |
download | cpython-9c4756ea265b5ebd71c9ae59f3673c7cecb6f060.zip cpython-9c4756ea265b5ebd71c9ae59f3673c7cecb6f060.tar.gz cpython-9c4756ea265b5ebd71c9ae59f3673c7cecb6f060.tar.bz2 |
Renamed PyBytes to PyByteArray
Diffstat (limited to 'Modules/_ctypes')
-rw-r--r-- | Modules/_ctypes/_ctypes.c | 2 | ||||
-rw-r--r-- | Modules/_ctypes/cfield.c | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/Modules/_ctypes/_ctypes.c b/Modules/_ctypes/_ctypes.c index 98c609c..1d548dc 100644 --- a/Modules/_ctypes/_ctypes.c +++ b/Modules/_ctypes/_ctypes.c @@ -1596,7 +1596,7 @@ c_void_p_from_param(PyObject *type, PyObject *value) return (PyObject *)parg; } /* bytes */ - if (PyBytes_Check(value)) { + if (PyByteArray_Check(value)) { PyCArgObject *parg; struct fielddesc *fd = getentry("z"); diff --git a/Modules/_ctypes/cfield.c b/Modules/_ctypes/cfield.c index 4e02563..86f6b53 100644 --- a/Modules/_ctypes/cfield.c +++ b/Modules/_ctypes/cfield.c @@ -1172,8 +1172,8 @@ c_set(void *ptr, PyObject *value, Py_ssize_t size) *(char *)ptr = PyString_AS_STRING(value)[0]; _RET(value); } - if (PyBytes_Check(value) && PyBytes_GET_SIZE(value) == 1) { - *(char *)ptr = PyBytes_AS_STRING(value)[0]; + if (PyByteArray_Check(value) && PyByteArray_GET_SIZE(value) == 1) { + *(char *)ptr = PyByteArray_AS_STRING(value)[0]; _RET(value); } if (PyLong_Check(value)) |