Mercurial > cpython-lru_cache-weakref
diff Python/future.c @ 37558:286c81689826 legacy-trunk
Use PyObject_* allocator since FutureFeatures is small
| author | Neal Norwitz <nnorwitz@gmail.com> |
|---|---|
| date | Mon, 10 Apr 2006 06:57:06 +0000 |
| parents | cea54c9d921d |
| children | f448d0075691 |
line wrap: on
line diff
--- a/Python/future.c Mon Apr 10 06:42:25 2006 +0000 +++ b/Python/future.c Mon Apr 10 06:57:06 2006 +0000 @@ -120,14 +120,14 @@ { PyFutureFeatures *ff; - ff = (PyFutureFeatures *)PyMem_Malloc(sizeof(PyFutureFeatures)); + ff = (PyFutureFeatures *)PyObject_Malloc(sizeof(PyFutureFeatures)); if (ff == NULL) return NULL; ff->ff_features = 0; ff->ff_lineno = -1; if (!future_parse(ff, mod, filename)) { - PyMem_Free((void *)ff); + PyObject_Free(ff); return NULL; } return ff;
