Home
last modified time | relevance | path

Searched refs:ob_bytes (Results 1 – 4 of 4) sorted by relevance

/external/python/cpython2/Objects/
Dbytearrayobject.c204 new->ob_bytes = NULL; in PyByteArray_FromStringAndSize()
209 new->ob_bytes = PyMem_Malloc(alloc); in PyByteArray_FromStringAndSize()
210 if (new->ob_bytes == NULL) { in PyByteArray_FromStringAndSize()
215 memcpy(new->ob_bytes, bytes, size); in PyByteArray_FromStringAndSize()
216 new->ob_bytes[size] = '\0'; /* Trailing null byte */ in PyByteArray_FromStringAndSize()
267 ((PyByteArrayObject *)self)->ob_bytes[size] = '\0'; /* Trailing null */ in PyByteArray_Resize()
279 sval = PyMem_Realloc(((PyByteArrayObject *)self)->ob_bytes, alloc); in PyByteArray_Resize()
285 ((PyByteArrayObject *)self)->ob_bytes = sval; in PyByteArray_Resize()
288 ((PyByteArrayObject *)self)->ob_bytes[size] = '\0'; /* Trailing null byte */ in PyByteArray_Resize()
316 memcpy(result->ob_bytes, va.buf, va.len); in PyByteArray_Concat()
[all …]
/external/python/cpython2/Include/
Dbytearrayobject.h27 char *ob_bytes; member
49 Py_SIZE(self) ? ((PyByteArrayObject *)(self))->ob_bytes : _PyByteArray_empty_string)
/external/python/cpython3/Objects/
Dbytearrayobject.c148 new->ob_bytes = NULL; in PyByteArray_FromStringAndSize()
153 new->ob_bytes = PyObject_Malloc(alloc); in PyByteArray_FromStringAndSize()
154 if (new->ob_bytes == NULL) { in PyByteArray_FromStringAndSize()
159 memcpy(new->ob_bytes, bytes, size); in PyByteArray_FromStringAndSize()
160 new->ob_bytes[size] = '\0'; /* Trailing null byte */ in PyByteArray_FromStringAndSize()
164 new->ob_start = new->ob_bytes; in PyByteArray_FromStringAndSize()
196 size_t logical_offset = (size_t) (obj->ob_start - obj->ob_bytes); in PyByteArray_Resize()
249 PyObject_Free(obj->ob_bytes); in PyByteArray_Resize()
252 sval = PyObject_Realloc(obj->ob_bytes, alloc); in PyByteArray_Resize()
259 obj->ob_bytes = obj->ob_start = sval; in PyByteArray_Resize()
[all …]
/external/python/cpython3/Include/
Dbytearrayobject.h26 char *ob_bytes; /* Physical backing buffer */ member