public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
From: Panu Matilainen <pmatilai@fedoraproject.org>
To: git-commits@fedoraproject.org
Subject: [rpms/rpm] pmatilai-v6: - fix segfault on failed url retrieval
Date: Mon, 23 Nov 2026 09:26:23 GMT [thread overview]
Message-ID: <179542598304.1.12754208089254598499.rpms-rpm-bbc081d94336@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/rpm
Branch : pmatilai-v6
Commit : bbc081d94336b541fad4fbd9e41c52b18974e7bb
Author : Panu Matilainen <pmatilai@fedoraproject.org>
Date : 2010-01-21T13:50:59+00:00
Stats : +53/-1 in 3 file(s)
URL : https://src.fedoraproject.org/rpms/rpm/c/bbc081d94336b541fad4fbd9e41c52b18974e7bb?branch=pmatilai-v6
Log:
- fix segfault on failed url retrieval
- fix verification error code depending on verbosity level
- if anything in testsuite fails, dump out the log
---
diff --git a/rpm-4.8.0-url-segfault.patch b/rpm-4.8.0-url-segfault.patch
new file mode 100644
index 0000000..e6f4b32
--- /dev/null
+++ b/rpm-4.8.0-url-segfault.patch
@@ -0,0 +1,19 @@
+commit ce1d2e87157f4a7ebc4f4d6f26024ac597400367
+Author: Panu Matilainen <pmatilai@redhat.com>
+Date: Thu Jan 21 13:45:34 2010 +0200
+
+ Fix double-free segfault on url retrieve to read-only media (RhBug:557118)
+
+diff --git a/lib/rpminstall.c b/lib/rpminstall.c
+index 6b3dde7..568e13f 100644
+--- a/lib/rpminstall.c
++++ b/lib/rpminstall.c
+@@ -458,7 +458,7 @@ restart:
+ case URL_IS_HTTPS:
+ case URL_IS_HTTP:
+ case URL_IS_FTP:
+- { char *tfn;
++ { char *tfn = NULL;
+ FD_t tfd;
+
+ if (rpmIsVerbose())
diff --git a/rpm-4.8.0-verify-exitcode.patch b/rpm-4.8.0-verify-exitcode.patch
new file mode 100644
index 0000000..46d4ed6
--- /dev/null
+++ b/rpm-4.8.0-verify-exitcode.patch
@@ -0,0 +1,22 @@
+commit 04ad4b1155ec4b082fbac425a575a0ba05337ab1
+Author: Panu Matilainen <pmatilai@redhat.com>
+Date: Thu Jan 21 14:14:28 2010 +0200
+
+ Really fix verification error code to not depend on verbosity (RhBug:557101)
+ - earlier fix from commit 6649c23cac5823d0c7415df5cfd66e5aac5eebd2 was
+ broken as it could reset return code to zero after detecting errors
+ earlier
+
+diff --git a/lib/verify.c b/lib/verify.c
+index 44ab314..1068cfe 100644
+--- a/lib/verify.c
++++ b/lib/verify.c
+@@ -353,7 +353,7 @@ static int verifyHeader(QVA_t qva, const rpmts ts, Header h)
+ static const char *const aok = ".";
+ static const char *const unknown = "?";
+
+- ec = (verifyResult != 0);
++ if (verifyResult) ec = 1;
+
+ #define _verify(_RPMVERIFY_F, _C) \
+ ((verifyResult & _RPMVERIFY_F) ? _C : aok)
diff --git a/rpm.spec b/rpm.spec
index 978ed87..8a2a3b7 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -21,7 +21,7 @@
Summary: The RPM package management system
Name: rpm
Version: %{rpmver}
-Release: 2%{?dist}
+Release: 3%{?dist}
Group: System Environment/Base
Url: http://www.rpm.org/
Source0: http://rpm.org/releases/testing/%{name}-%{srcver}.tar.bz2
@@ -37,6 +37,8 @@ Patch2: rpm-4.5.90-gstreamer-provides.patch
Patch3: rpm-4.7.90-fedora-specspo.patch
# Patches already in upstream
+Patch200: rpm-4.8.0-url-segfault.patch
+Patch201: rpm-4.8.0-verify-exitcode.patch
# These are not yet upstream
Patch301: rpm-4.6.0-niagara.patch
@@ -181,6 +183,9 @@ packages on a system.
%patch2 -p1 -b .gstreamer-prov
%patch3 -p1 -b .fedora-specspo
+%patch200 -p1 -b .url-segfault
+%patch201 -p1 -b .verify-exitcode
+
%patch301 -p1 -b .niagara
%patch302 -p1 -b .geode
@@ -267,6 +272,7 @@ rm -rf $RPM_BUILD_ROOT
%if %{with check}
%check
make check
+[ "$(ls -A tests/rpmtests.dir)" ] && cat tests/rpmtests.log
%endif
%post libs -p /sbin/ldconfig
@@ -394,6 +400,11 @@ exit 0
%doc doc/librpm/html/*
%changelog
+* Thu Jan 21 2010 Panu Matilainen <pmatilai@redhat.com> - 4.8.0-3
+- fix segfault on failed url retrieval
+- fix verification error code depending on verbosity level
+- if anything in testsuite fails, dump out the log
+
* Fri Jan 08 2010 Panu Matilainen <pmatilai@redhat.com> - 4.8.0-2
- put disttag back, accidentally nuked in 4.8.0 final update
reply other threads:[~2026-11-23 9:26 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=179542598304.1.12754208089254598499.rpms-rpm-bbc081d94336@fedoraproject.org \
--to=pmatilai@fedoraproject.org \
--cc=git-commits@fedoraproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox