public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/rpm] pmatilai-v6: - don't hang because of leftover query iterators (#246044)
@ 2026-11-23  9:24 Panu Matilainen
  0 siblings, 0 replies; only message in thread
From: Panu Matilainen @ 2026-11-23  9:24 UTC (permalink / raw)
  To: git-commits

A new commit has been pushed.

Repo   : rpms/rpm
Branch : pmatilai-v6
Commit : 66621c977c90c2daaebc88b38e303e32c2940b73
Author : Panu Matilainen <pmatilai@fedoraproject.org>
Date   : 2007-06-28T12:02:23+00:00
Stats  : +31/-1 in 2 file(s)
URL    : https://src.fedoraproject.org/rpms/rpm/c/66621c977c90c2daaebc88b38e303e32c2940b73?branch=pmatilai-v6

Log:
- don't hang because of leftover query iterators (#246044)

---
diff --git a/rpm-4.4.2.1-rc1-query-iterators.patch b/rpm-4.4.2.1-rc1-query-iterators.patch
new file mode 100644
index 0000000..4aa1620
--- /dev/null
+++ b/rpm-4.4.2.1-rc1-query-iterators.patch
@@ -0,0 +1,25 @@
+changeset:   6070:7ca081cd83d8
+tag:         tip
+user:        Panu Matilainen <pmatilai@redhat.com>
+date:        Thu Jun 28 14:44:48 2007 +0300
+summary:     Remember to free up match iterators (rhbz#246044)
+
+diff -r a468a8443652 -r 7ca081cd83d8 lib/query.c
+--- a/lib/query.c	Wed Jun 27 16:29:16 2007 +0300
++++ b/lib/query.c	Thu Jun 28 14:44:48 2007 +0300
+@@ -680,10 +680,12 @@ int rpmQueryVerify(QVA_t qva, rpmts ts, 
+     case RPMQV_PACKAGE:
+     {
+ 	int matches = 0;
+-	qva->qva_mi = rpmtsInitIterator(ts, RPMDBI_LABEL, arg, 0);
+-	while (rpmdbNextIterator(qva->qva_mi) != NULL) {
++	rpmdbMatchIterator mi;
++	mi = rpmtsInitIterator(ts, RPMDBI_LABEL, arg, 0);
++	while (rpmdbNextIterator(mi) != NULL) {
+ 	    matches++;
+ 	}
++	rpmdbFreeIterator(mi);
+ 	if (! matches) {
+ 	    rpmError(RPMERR_QUERYINFO, _("package %s is not installed\n"), arg);
+ 	    res = 1;
+

diff --git a/rpm.spec b/rpm.spec
index b7a9d0c..bd48497 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -14,7 +14,7 @@ Summary: The RPM package management system
 Name: rpm
 Version: 4.4.2.1
 %{expand: %%define rpm_version %{version}-rc1}
-Release: 0.2.rc1
+Release: 0.3.rc1
 Group: System Environment/Base
 Url: http://www.rpm.org/
 Source: rpm-%{rpm_version}.tar.gz
@@ -25,6 +25,7 @@ Patch4: rpm-4.4.2-devel-autodep.patch
 Patch5: rpm-4.4.2-rpmfc-skip.patch
 Patch6: rpm-4.4.2-matchpathcon.patch
 Patch7: rpm-4.4.2.1-rc1-poptver.patch
+Patch8: rpm-4.4.2.1-rc1-query-iterators.patch
 License: GPL
 Requires(pre): shadow-utils
 Requires(postun): shadow-utils
@@ -135,6 +136,7 @@ shell-like rules.
 %patch5 -p1 -b .fcskip
 %patch6 -p1 -b .matchpathcon
 %patch7 -p1 -b .poptver
+%patch8 -p1 -b .queryiter
 
 %build
 
@@ -429,6 +431,9 @@ exit 0
 %{__includedir}/popt.h
 
 %changelog
+* Thu Jun 28 2007 Panu Matilainen <pmatilai@redhat.com> 4.4.2.1-0.3.rc1
+- don't hang because of leftover query iterators (#246044)
+
 * Tue Jun 26 2007 Panu Matilainen <pmatilai@redhat.com> 4.4.2.1-0.2.rc1
 - patch popt version to 1.10.2.1 for clean upgrade path
 - popt release follows main package release again

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-11-23  9:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-23  9:24 [rpms/rpm] pmatilai-v6: - don't hang because of leftover query iterators (#246044) Panu Matilainen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox