rpms/jwhois/devel jwhois-3.2.3-sigpipe.patch, NONE, 1.1 jwhois.spec, 1.19, 1.20
fedora-cvs-commits at redhat.com
fedora-cvs-commits at redhat.com
Fri Aug 5 13:33:15 UTC 2005
Author: mitr
Update of /cvs/dist/rpms/jwhois/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv31280
Modified Files:
jwhois.spec
Added Files:
jwhois-3.2.3-sigpipe.patch
Log Message:
* Fri Aug 5 2005 Miloslav Trmac <mitr at redhat.com> - 3.2.3-2
- Don't die on SIGPIPE if a browser is not present, improve the error message
(#165149)
jwhois-3.2.3-sigpipe.patch:
http.c | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletion(-)
--- NEW FILE jwhois-3.2.3-sigpipe.patch ---
--- jwhois-3.2.3/src/http.c.sigpipe 2005-08-05 15:06:34.000000000 +0200
+++ jwhois-3.2.3/src/http.c 2005-08-05 15:18:12.000000000 +0200
@@ -19,6 +19,7 @@
#include <config.h>
+#include <signal.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
@@ -269,7 +270,8 @@
/* Drats! */
if (errno)
{
- printf("[HTTP: %s: %s]\n", _("Unable to run web browser"), strerror(errno));
+ printf("[HTTP: %s: %s: %s]\n", _("Unable to run web browser"),
+ command[0], strerror(errno));
}
close(to_browser[0]);
close(from_browser[1]);
@@ -287,6 +289,8 @@
if (!isget && !post_as_file)
{
+ struct sigaction sa, old_sa;
+
/* Send POST data */
if (format)
{
@@ -301,7 +305,12 @@
element, wq->query,
extra ? "&" : "", extra ? extra : "");
}
+ sa.sa_handler = SIG_IGN;
+ sigemptyset (&sa.sa_mask);
+ sa.sa_flags = 0;
+ sigaction (SIGPIPE, &sa, &old_sa);
write(to_browser[1], data, strlen(data) + 1);
+ sigaction (SIGPIPE, &old_sa, NULL);
}
close(to_browser[1]);
Index: jwhois.spec
===================================================================
RCS file: /cvs/dist/rpms/jwhois/devel/jwhois.spec,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -r1.19 -r1.20
--- jwhois.spec 1 Aug 2005 01:43:17 -0000 1.19
+++ jwhois.spec 5 Aug 2005 13:33:12 -0000 1.20
@@ -1,12 +1,13 @@
Name: jwhois
Version: 3.2.3
-Release: 1
+Release: 2
URL: http://www.gnu.org/software/jwhois/
Source0: ftp://ftp.gnu.org/gnu/jwhois/jwhois-%{version}.tar.gz
Source1: ftp://ftp.gnu.org/gnu/jwhois/jwhois-%{version}.tar.gz.sig
#Patch0: jwhois-3.2.3-config-cvs.patch
Patch1: jwhois-3.2.2-afrinic.patch
Patch2: jwhois-3.2.2-ru.patch
+Patch3: jwhois-3.2.3-sigpipe.patch
License: GPL
Group: Applications/Internet
Summary: Internet whois/nicname client.
@@ -22,6 +23,7 @@
#patch0 -p0 -b .config
%patch1 -p1 -b .afrinic
%patch2 -p1 -b .ru
+%patch3 -p1 -b .sigpipe
iconv -f iso-8859-1 -t utf-8 < doc/sv/jwhois.1 > doc/sv/jwhois.1_
mv doc/sv/jwhois.1_ doc/sv/jwhois.1
@@ -33,6 +35,7 @@
%install
[ "$RPM_BUILD_ROOT" != "/" ] && rm -fr $RPM_BUILD_ROOT
make install DESTDIR="$RPM_BUILD_ROOT"
+rm -f "$RPM_BUILD_ROOT"%{_infodir}/dir
%find_lang jwhois
# Make "whois" jwhois.
@@ -45,7 +48,6 @@
%{_bindir}/*
%{_mandir}/man1/*
%{_mandir}/*/man1/jwhois.1*
-%exclude %{_infodir}/dir
%{_infodir}/jwhois.info.gz
%config(noreplace) %{_sysconfdir}/jwhois.conf
@@ -61,6 +63,10 @@
[ "$RPM_BUILD_ROOT" != "/" ] && rm -fr $RPM_BUILD_ROOT
%changelog
+* Fri Aug 5 2005 Miloslav Trmac <mitr at redhat.com> - 3.2.3-2
+- Don't die on SIGPIPE if a browser is not present, improve the error message
+ (#165149)
+
* Mon Aug 1 2005 Miloslav Trmac <mitr at redhat.com> - 3.2.3-1
- Update to jwhois-3.2.3
- Don't compress jwhois.info manually
More information about the fedora-cvs-commits
mailing list