diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2012-01-10 10:38:31 +0200 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2012-01-10 10:38:31 +0200 |
commit | 8605a4b034237f0afeebe852862e7d7ceb4b8f11 (patch) | |
tree | 9659ad14c002b4b07a173ad6e838c3a2aedd8efc /python | |
parent | fecba496374472db3d61d96bbfb72399ab93f756 (diff) | |
download | librpm-tizen-8605a4b034237f0afeebe852862e7d7ceb4b8f11.tar.gz librpm-tizen-8605a4b034237f0afeebe852862e7d7ceb4b8f11.tar.bz2 librpm-tizen-8605a4b034237f0afeebe852862e7d7ceb4b8f11.zip |
Transaction element parent is a transaction element, not an integer
- Ehm, this has been broken in the python bindings since the start,
nobody noticed. Of course the parent value isn't particularly
useful in normal usage but still...
Diffstat (limited to 'python')
-rw-r--r-- | python/rpmte-py.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/python/rpmte-py.c b/python/rpmte-py.c index f15824780..2204a5281 100644 --- a/python/rpmte-py.c +++ b/python/rpmte-py.c @@ -114,7 +114,11 @@ rpmte_PkgFileSize(rpmteObject * s, PyObject * unused) static PyObject * rpmte_Parent(rpmteObject * s, PyObject * unused) { - return Py_BuildValue("i", rpmteParent(s->te)); + rpmte parent = rpmteParent(s->te); + if (parent) + return rpmte_Wrap(&rpmte_Type, parent); + + Py_RETURN_NONE; } static PyObject * rpmte_Failed(rpmteObject * s, PyObject * unused) |