Fix minor header iterator leak in rpmReSign()
- fix dumb double-initialization error introduced somewhere between 4.4 and 4.6, also while-loop is more natural here than for-loop
This commit is contained in:
parent
a592b14fe2
commit
834c838347
|
@ -221,12 +221,10 @@ static int rpmReSign(rpmts ts, QVA_t qva, ARGV_const_t argv)
|
|||
|
||||
oh = headerCopyLoad(utd.data);
|
||||
hi = headerInitIterator(oh);
|
||||
for (hi = headerInitIterator(oh);
|
||||
headerNext(hi, ©td);
|
||||
rpmtdFreeData(©td))
|
||||
{
|
||||
while (headerNext(hi, ©td)) {
|
||||
if (copytd.data)
|
||||
xx = headerPut(nh, ©td, HEADERPUT_DEFAULT);
|
||||
rpmtdFreeData(©td);
|
||||
}
|
||||
hi = headerFreeIterator(hi);
|
||||
oh = headerFree(oh);
|
||||
|
|
Loading…
Reference in New Issue