diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2010-03-22 14:45:49 +0200 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2010-03-22 14:45:49 +0200 |
commit | 36e4ef1a0adab54a9a06e9b1d6beff80a049d892 (patch) | |
tree | f7cd19758e18a2263f4165993af4f3a9d7e05490 /lib | |
parent | c7f62698441b347920a3f9f7c9b53ed24bb89c25 (diff) | |
download | librpm-tizen-36e4ef1a0adab54a9a06e9b1d6beff80a049d892.tar.gz librpm-tizen-36e4ef1a0adab54a9a06e9b1d6beff80a049d892.tar.bz2 librpm-tizen-36e4ef1a0adab54a9a06e9b1d6beff80a049d892.zip |
Take a transaction set reference on verified db iteration
- forward linking hasn't been an issue since >= 4.6.0...
Diffstat (limited to 'lib')
-rw-r--r-- | lib/rpmdb.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/rpmdb.c b/lib/rpmdb.c index 65b7e2479..3edb35bfe 100644 --- a/lib/rpmdb.c +++ b/lib/rpmdb.c @@ -27,6 +27,7 @@ #include <rpm/rpmds.h> /* XXX isInstallPreReq macro only */ #include <rpm/rpmlog.h> #include <rpm/rpmdb.h> +#include <rpm/rpmts.h> #include <rpm/argv.h> #include "lib/rpmdb_internal.h" @@ -1460,6 +1461,7 @@ rpmdbMatchIterator rpmdbFreeIterator(rpmdbMatchIterator mi) mi->mi_set = dbiFreeIndexSet(mi->mi_set); mi->mi_keyp = _free(mi->mi_keyp); mi->mi_db = rpmdbUnlink(mi->mi_db); + mi->mi_ts = rpmtsFree(mi->mi_ts); mi = _free(mi); @@ -1816,8 +1818,7 @@ int rpmdbSetHdrChk(rpmdbMatchIterator mi, rpmts ts, int rc = 0; if (mi == NULL) return 0; - /* XXX forward linkage prevents rpmtsLink */ - mi->mi_ts = ts; + mi->mi_ts = rpmtsLink(ts); mi->mi_hdrchk = hdrchk; return rc; } |