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 a potential getOutputFrom() error from font provide extraction
Date: Mon, 23 Nov 2026 09:26:42 GMT [thread overview]
Message-ID: <179542600231.1.8061656855537225387.rpms-rpm-cc06306cbe59@fedoraproject.org> (raw)
A new commit has been pushed.
Repo : rpms/rpm
Branch : pmatilai-v6
Commit : cc06306cbe59d1a226c77209a072c9640d1b7bde
Author : Panu Matilainen <pmatilai@fedoraproject.org>
Date : 2010-06-30T09:44:37+00:00
Stats : +68/-1 in 3 file(s)
URL : https://src.fedoraproject.org/rpms/rpm/c/cc06306cbe59d1a226c77209a072c9640d1b7bde?branch=pmatilai-v6
Log:
- fix a potential getOutputFrom() error from font provide extraction
- debug-friendlier message to aid finding other similar cases (#565223)
---
diff --git a/rpm-4.8.1-eat-stdin.patch b/rpm-4.8.1-eat-stdin.patch
new file mode 100644
index 0000000..83af219
--- /dev/null
+++ b/rpm-4.8.1-eat-stdin.patch
@@ -0,0 +1,31 @@
+From 53045d5dcdce3988e2586cb315b35e6a675a8152 Mon Sep 17 00:00:00 2001
+From: Panu Matilainen <pmatilai@redhat.com>
+Date: Wed, 30 Jun 2010 11:57:17 +0300
+Subject: [PATCH 1/2] Fix potential getOutputFrom() error on font provide extraction (RhBug:609117)
+ - if fonts are detected in the package being built but fc-query isn't
+ present, the script exited without consuming stdin which can break
+ getOutputFrom()
+
+---
+ scripts/fontconfig.prov | 5 ++++-
+ 1 files changed, 4 insertions(+), 1 deletions(-)
+
+diff --git a/scripts/fontconfig.prov b/scripts/fontconfig.prov
+index 8638680..594851d 100755
+--- a/scripts/fontconfig.prov
++++ b/scripts/fontconfig.prov
+@@ -12,7 +12,10 @@
+
+ fcquery=/usr/bin/fc-query
+
+-[ -x $fcquery ] || exit 0
++if [ -x $fcquery ]; then
++ cat > /dev/null
++ exit 0
++fi
+
+ # filter out anything outside main fontconfig path
+ grep /usr/share/fonts/ |
+--
+1.7.0.1
+
diff --git a/rpm-4.8.1-getoutput-emsg.patch b/rpm-4.8.1-getoutput-emsg.patch
new file mode 100644
index 0000000..4586155
--- /dev/null
+++ b/rpm-4.8.1-getoutput-emsg.patch
@@ -0,0 +1,28 @@
+From 5711982e27c70bea4017632255a94630ea10d1ab Mon Sep 17 00:00:00 2001
+From: Panu Matilainen <pmatilai@redhat.com>
+Date: Wed, 30 Jun 2010 12:27:56 +0300
+Subject: [PATCH 2/2] Make the infamous getOutputFrom() error message more useful
+ - ...like actually saying what was the failing script, doh
+ - leaving the function name there for a googling hint
+
+---
+ build/rpmfc.c | 3 ++-
+ 1 files changed, 2 insertions(+), 1 deletions(-)
+
+diff --git a/build/rpmfc.c b/build/rpmfc.c
+index e76363a..3c915f5 100644
+--- a/build/rpmfc.c
++++ b/build/rpmfc.c
+@@ -234,7 +234,8 @@ top:
+ if ((nbw = write(toProg[1], writePtr,
+ (1024<writeBytesLeft) ? 1024 : writeBytesLeft)) < 0) {
+ if (errno != EAGAIN) {
+- perror("getOutputFrom()");
++ rpmlog(RPMLOG_ERR, _("%s: failure writing to %s: %m\n"),
++ __func__, argv[0]);
+ exit(EXIT_FAILURE);
+ }
+ nbw = 0;
+--
+1.7.0.1
+
diff --git a/rpm.spec b/rpm.spec
index 176eaf2..b666603 100644
--- a/rpm.spec
+++ b/rpm.spec
@@ -21,7 +21,7 @@
Summary: The RPM package management system
Name: rpm
Version: %{rpmver}
-Release: 1%{?dist}
+Release: 2%{?dist}
Group: System Environment/Base
Url: http://www.rpm.org/
Source0: http://rpm.org/releases/rpm-4.8.x/%{name}-%{srcver}.tar.bz2
@@ -44,6 +44,8 @@ Patch5: rpm-4.8.0-no-man-dirs.patch
Patch200: rpm-4.8.0-pythondeps-parallel.patch
Patch201: rpm-4.8.0-python-bytecompile.patch
Patch202: rpm-4.8.0-findlang-localedirs.patch
+Patch203: rpm-4.8.1-eat-stdin.patch
+Patch204: rpm-4.8.1-getoutput-emsg.patch
# These are not yet upstream
Patch301: rpm-4.6.0-niagara.patch
@@ -194,6 +196,8 @@ packages on a system.
%patch200 -p1 -b .pythondeps-parallel
%patch201 -p1 -b .python-bytecompile
%patch202 -p1 -b .findlang-localedirs
+%patch203 -p1 -b .eat-stdin
+%patch204 -p1 -b .getoutput-emsg
%patch301 -p1 -b .niagara
%patch302 -p1 -b .geode
@@ -410,6 +414,10 @@ exit 0
%doc doc/librpm/html/*
%changelog
+* Wed Jun 30 2010 Panu Matilainen <pmatilai@redhat.com> - 4.8.1-2
+- fix a potential getOutputFrom() error from font provide extraction
+- debug-friendlier message to aid finding other similar cases (#565223)
+
* Fri Jun 11 2010 Panu Matilainen <pmatilai@redhat.com> - 4.8.1-1
- update to 4.8.1 (http://rpm.org/wiki/Releases/4.8.1)
- drop no longer needed patches
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=179542600231.1.8061656855537225387.rpms-rpm-cc06306cbe59@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