summaryrefslogtreecommitdiff
path: root/python/rpmmi-py.c
diff options
context:
space:
mode:
authorPanu Matilainen <pmatilai@redhat.com>2009-09-22 20:20:07 +0300
committerPanu Matilainen <pmatilai@redhat.com>2009-09-22 20:20:07 +0300
commit0793b2cf23667f515c1675e9dbe37e634c4cd730 (patch)
tree1dfef0e3a9f3f3e51911cbf443356b48d4decf93 /python/rpmmi-py.c
parentd7134660ca4300058e579bed990ab7cf7e14a40f (diff)
downloadlibrpm-tizen-0793b2cf23667f515c1675e9dbe37e634c4cd730.tar.gz
librpm-tizen-0793b2cf23667f515c1675e9dbe37e634c4cd730.tar.bz2
librpm-tizen-0793b2cf23667f515c1675e9dbe37e634c4cd730.zip
All rpm-python iterators are self-iterators, just use PyObject_SelfIter
Diffstat (limited to 'python/rpmmi-py.c')
-rw-r--r--python/rpmmi-py.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/python/rpmmi-py.c b/python/rpmmi-py.c
index 08b02e840..ea9941f5f 100644
--- a/python/rpmmi-py.c
+++ b/python/rpmmi-py.c
@@ -76,15 +76,6 @@ struct rpmmiObject_s {
/**
*/
static PyObject *
-rpmmi_iter(rpmmiObject * s)
-{
- Py_INCREF(s);
- return (PyObject *)s;
-}
-
-/**
- */
-static PyObject *
rpmmi_iternext(rpmmiObject * s)
{
Header h;
@@ -221,7 +212,7 @@ PyTypeObject rpmmi_Type = {
0, /* tp_clear */
0, /* tp_richcompare */
0, /* tp_weaklistoffset */
- (getiterfunc) rpmmi_iter, /* tp_iter */
+ PyObject_SelfIter, /* tp_iter */
(iternextfunc) rpmmi_iternext, /* tp_iternext */
rpmmi_methods, /* tp_methods */
0, /* tp_members */