diff options
author | Panu Matilainen <pmatilai@redhat.com> | 2011-05-28 22:28:53 +0300 |
---|---|---|
committer | Panu Matilainen <pmatilai@redhat.com> | 2011-05-28 22:28:53 +0300 |
commit | d26080fa88d695396068543c7be88c9ffbf2307c (patch) | |
tree | d0cdd60640b387a165463fc188831e143d2e27c4 | |
parent | 9f72c7f2cda74172bfe5c6c558f4c20b783ad115 (diff) | |
download | librpm-tizen-d26080fa88d695396068543c7be88c9ffbf2307c.tar.gz librpm-tizen-d26080fa88d695396068543c7be88c9ffbf2307c.tar.bz2 librpm-tizen-d26080fa88d695396068543c7be88c9ffbf2307c.zip |
Eliminate dead NULL-assignments at scope-end in librpm, part IV
- Remove NULL-assignments of local variables at the end of scope
in the higher level package-related "objects": rpmds, rpmfi, rpmte
-rw-r--r-- | lib/rpmds.c | 6 | ||||
-rw-r--r-- | lib/rpmfi.c | 2 | ||||
-rw-r--r-- | lib/rpmte.c | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/lib/rpmds.c b/lib/rpmds.c index 3dff6cb55..a62bb8d31 100644 --- a/lib/rpmds.c +++ b/lib/rpmds.c @@ -784,7 +784,7 @@ int rpmdsMatchesDep (const Header h, int ix, const rpmds req, int nopromote) rpmdsSetIx(provides,ix); result = rpmdsCompare(provides, req); - provides = rpmdsFree(provides); + rpmdsFree(provides); return result; } @@ -810,7 +810,7 @@ int rpmdsAnyMatchesDep (const Header h, const rpmds req, int nopromote) } exit: - provides = rpmdsFree(provides); + rpmdsFree(provides); return result; } @@ -909,7 +909,7 @@ int rpmdsRpmlib(rpmds * dsp, const void * tblp) rpmds ds = rpmdsSingle(RPMTAG_PROVIDENAME, rlp->featureName, rlp->featureEVR, rlp->featureFlags); rc = rpmdsMerge(dsp, ds); - ds = rpmdsFree(ds); + rpmdsFree(ds); } return rc; } diff --git a/lib/rpmfi.c b/lib/rpmfi.c index 5a34d75ca..e1e8fa9fa 100644 --- a/lib/rpmfi.c +++ b/lib/rpmfi.c @@ -783,7 +783,7 @@ static int addPrefixes(Header h, rpmRelocation *relocations, int numRelocations) if (numActual) { headerPutStringArray(h, RPMTAG_INSTPREFIXES, actualRelocations, numActual); } - actualRelocations = _free(actualRelocations); + free(actualRelocations); return numActual; } diff --git a/lib/rpmte.c b/lib/rpmte.c index d13575ac1..448a35af9 100644 --- a/lib/rpmte.c +++ b/lib/rpmte.c @@ -627,7 +627,7 @@ static Header rpmteDBHeader(rpmte te) /* iterator returns weak refs, grab hold of header */ if ((h = rpmdbNextIterator(mi))) h = headerLink(h); - mi = rpmdbFreeIterator(mi); + rpmdbFreeIterator(mi); return h; } |