Skip to content

Commit 6e4b910

Browse files
committed
1 parent 9887dad commit 6e4b910

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Objects/bytearrayobject.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2705,10 +2705,10 @@ bytearray_sizeof_impl(PyByteArrayObject *self)
27052705
/*[clinic end generated code: output=738abdd17951c427 input=e27320fd98a4bc5a]*/
27062706
{
27072707
Py_ssize_t res = _PyObject_SIZE(Py_TYPE(self));
2708-
Py_ssize_t alloc = FT_ATOMIC_LOAD_SSIZE_RELAXED(self->ob_alloc) * sizeof(char);
2708+
Py_ssize_t alloc = FT_ATOMIC_LOAD_SSIZE_RELAXED(self->ob_alloc);
27092709
if (alloc > 0) {
27102710
res += sizeof(PyBytesObject);
2711-
res += alloc * sizeof(char);
2711+
res += alloc;
27122712
}
27132713

27142714
return PyLong_FromSize_t(res);

0 commit comments

Comments
 (0)