diff --git a/python/rpmds-py.c b/python/rpmds-py.c index 2820d67e0..7b54aa7b5 100644 --- a/python/rpmds-py.c +++ b/python/rpmds-py.c @@ -517,17 +517,6 @@ fprintf(stderr, "%p -- ds %p\n", s, s->ds); PyObject_Del((PyObject *)s); } -/** \ingroup py_c - */ -static PyObject * rpmds_alloc(PyTypeObject * subtype, int nitems) -{ - PyObject * s = PyType_GenericAlloc(subtype, nitems); - -if (_rpmds_debug < 0) -fprintf(stderr, "*** rpmds_alloc(%p,%d) ret %p\n", subtype, nitems, s); - return s; -} - /** \ingroup py_c */ static PyObject * rpmds_new(PyTypeObject * subtype, PyObject *args, PyObject *kwds) @@ -591,7 +580,7 @@ PyTypeObject rpmds_Type = { 0, /* tp_descr_set */ 0, /* tp_dictoffset */ (initproc) rpmds_init, /* tp_init */ - (allocfunc) rpmds_alloc, /* tp_alloc */ + 0, /* tp_alloc */ (newfunc) rpmds_new, /* tp_new */ (freefunc) rpmds_free, /* tp_free */ 0, /* tp_is_gc */ diff --git a/python/rpmfi-py.c b/python/rpmfi-py.c index ec630e37f..61bcb324f 100644 --- a/python/rpmfi-py.c +++ b/python/rpmfi-py.c @@ -409,17 +409,6 @@ fprintf(stderr, "%p -- fi %p\n", s, s->fi); PyObject_Del((PyObject *)s); } -/** \ingroup py_c - */ -static PyObject * rpmfi_alloc(PyTypeObject * subtype, int nitems) -{ - PyObject * s = PyType_GenericAlloc(subtype, nitems); - -if (_rpmfi_debug < 0) -fprintf(stderr, "*** rpmfi_alloc(%p,%d) ret %p\n", subtype, nitems, s); - return s; -} - /** \ingroup py_c */ static PyObject * rpmfi_new(PyTypeObject * subtype, PyObject *args, PyObject *kwds) @@ -482,7 +471,7 @@ PyTypeObject rpmfi_Type = { 0, /* tp_descr_set */ 0, /* tp_dictoffset */ (initproc) rpmfi_init, /* tp_init */ - (allocfunc) rpmfi_alloc, /* tp_alloc */ + 0, /* tp_alloc */ (newfunc) rpmfi_new, /* tp_new */ (freefunc) rpmfi_free, /* tp_free */ 0, /* tp_is_gc */ diff --git a/python/rpmps-py.c b/python/rpmps-py.c index 875d785f3..7355d18bd 100644 --- a/python/rpmps-py.c +++ b/python/rpmps-py.c @@ -190,17 +190,6 @@ fprintf(stderr, "%p -- ps %p\n", s, s->ps); PyObject_Del((PyObject *)s); } -/** \ingroup py_c - */ -static PyObject * rpmps_alloc(PyTypeObject * subtype, int nitems) -{ - PyObject * s = PyType_GenericAlloc(subtype, nitems); - -if (_rpmps_debug < 0) -fprintf(stderr, "*** rpmps_alloc(%p,%d) ret %p\n", subtype, nitems, s); - return s; -} - /** \ingroup py_c */ static PyObject * rpmps_new(PyTypeObject * subtype, PyObject *args, PyObject *kwds) @@ -263,7 +252,7 @@ PyTypeObject rpmps_Type = { 0, /* tp_descr_set */ 0, /* tp_dictoffset */ (initproc) rpmps_init, /* tp_init */ - (allocfunc) rpmps_alloc, /* tp_alloc */ + 0, /* tp_alloc */ (newfunc) rpmps_new, /* tp_new */ (freefunc) rpmps_free, /* tp_free */ 0, /* tp_is_gc */ diff --git a/python/rpmts-py.c b/python/rpmts-py.c index 169f6744a..7d7197eb2 100644 --- a/python/rpmts-py.c +++ b/python/rpmts-py.c @@ -1286,17 +1286,6 @@ fprintf(stderr, "%p -- ts %p db %p\n", s, s->ts, rpmtsGetRdb(s->ts)); PyObject_Del((PyObject *)s); } -/** \ingroup py_c - */ -static PyObject * rpmts_alloc(PyTypeObject * subtype, int nitems) -{ - PyObject * s = PyType_GenericAlloc(subtype, nitems); - -if (_rpmts_debug < 0) -fprintf(stderr, "*** rpmts_alloc(%p,%d) ret %p\n", subtype, nitems, s); - return s; -} - /** \ingroup py_c */ static PyObject * rpmts_new(PyTypeObject * subtype, PyObject *args, PyObject *kwds) @@ -1376,7 +1365,7 @@ PyTypeObject rpmts_Type = { 0, /* tp_descr_set */ 0, /* tp_dictoffset */ (initproc) rpmts_init, /* tp_init */ - (allocfunc) rpmts_alloc, /* tp_alloc */ + 0, /* tp_alloc */ (newfunc) rpmts_new, /* tp_new */ (freefunc) rpmts_free, /* tp_free */ 0, /* tp_is_gc */