parseSignArgs call fails on sucess

Bug #1776815 reported by Peter Howe
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
rpm (Ubuntu)
New
Undecided
Unassigned

Bug Description

for version 4.14.1+dfsg1-2.dpkg affects python3-rpm

in python/rpmsmodule.c the two calls to parseSignArgs in addSign and delSign should be inverted:

--- rpm-4.14.1+dfsg1.orig/python/rpmsmodule.c
+++ rpm-4.14.1+dfsg1/python/rpmsmodule.c
@@ -20,7 +20,7 @@ static PyObject * addSign(PyObject * sel
     const char *path = NULL;
     struct rpmSignArgs sargs;

- if (parseSignArgs(args, kwds, &path, &sargs))
+ if (!parseSignArgs(args, kwds, &path, &sargs))
     return NULL;

     return PyBool_FromLong(rpmPkgSign(path, &sargs) == 0);
@@ -31,7 +31,7 @@ static PyObject * delSign(PyObject * sel
     const char *path = NULL;
     struct rpmSignArgs sargs;

- if (parseSignArgs(args, kwds, &path, &sargs))
+ if (!parseSignArgs(args, kwds, &path, &sargs))
     return NULL;

     return PyBool_FromLong(rpmPkgDelSign(path, &sargs) == 0);

This is fixed in newer upstream, but not in 4.14.1.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.