diff options
-rw-r--r-- | Modules/_ctypes/_ctypes.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_ctypes/_ctypes.c b/Modules/_ctypes/_ctypes.c index c1956945c9..62a083b33d 100644 --- a/Modules/_ctypes/_ctypes.c +++ b/Modules/_ctypes/_ctypes.c @@ -1326,7 +1326,7 @@ PyCArrayType_new(PyTypeObject *type, PyObject *args, PyObject *kwds) if (stgdict->format == NULL) goto error; stgdict->ndim = itemdict->ndim + 1; - stgdict->shape = PyMem_Malloc(sizeof(Py_ssize_t *) * stgdict->ndim); + stgdict->shape = PyMem_Malloc(sizeof(Py_ssize_t) * stgdict->ndim); if (stgdict->shape == NULL) goto error; stgdict->shape[0] = length; |