rpms/rusers/devel netkit-rusers-0.17-return.patch, NONE, 1.1 rusers.spec, 1.20, 1.21

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Tue Mar 21 13:38:01 UTC 2006


Author: pknirsch

Update of /cvs/dist/rpms/rusers/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv30857

Modified Files:
	rusers.spec 
Added Files:
	netkit-rusers-0.17-return.patch 
Log Message:
- Included fix for correct return values for rup (#177419)


netkit-rusers-0.17-return.patch:
 rup.c |   12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)

--- NEW FILE netkit-rusers-0.17-return.patch ---
--- netkit-rusers-0.17/rup/rup.c.orig	2006-02-07 14:26:47.423011784 +0530
+++ netkit-rusers-0.17/rup/rup.c	2006-02-07 14:41:22.035029176 +0530
@@ -242,7 +242,7 @@
 }
 
 static
-void
+int
 onehost(const char *host)
 {
 	CLIENT *rstat_clnt;
@@ -251,7 +251,7 @@
 	rstat_clnt = clnt_create(host, RSTATPROG, RSTATVERS_TIME, "udp");
 	if (rstat_clnt == NULL) {
 		warnx("%s", clnt_spcreateerror(host));
-		return;
+		return 1;
 	}
 
 	memset(&remote_host_stat, 0, sizeof(remote_host_stat));
@@ -263,7 +263,7 @@
 		      timeout) != RPC_SUCCESS) 
 	{
 		warnx("%s",  clnt_sperror(rstat_clnt, host));
-		return;
+		return 1;
 	}
 
 	if (sort_type != SORT_NONE) {
@@ -272,19 +272,23 @@
 		print_rup_data(host, &remote_host_stat);
 	}
 	clnt_destroy(rstat_clnt);
+	return 0;
 }
 
 static
 void
 enumhosts(int argc, char *argv[], int optind)
 {
+	int returnval = 0;
 	if (sort_type != SORT_NONE) {
 		printf("collecting responses...");
 		fflush(stdout);
 	}
 
 	for (; optind < argc; optind++)
-		onehost(argv[optind]);
+		returnval += onehost(argv[optind]);
+
+	if (returnval) exit(1);
 
 	if (sort_type != SORT_NONE) {
 		int i;


Index: rusers.spec
===================================================================
RCS file: /cvs/dist/rpms/rusers/devel/rusers.spec,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -r1.20 -r1.21
--- rusers.spec	11 Feb 2006 05:37:14 -0000	1.20
+++ rusers.spec	21 Mar 2006 13:37:58 -0000	1.21
@@ -5,7 +5,7 @@
 Summary: Displays the users logged into machines on the local network.
 Name: rusers
 Version: 0.17
-Release: 45.2.1
+Release: 46
 License: BSD
 Group: System Environment/Daemons
 Source: ftp://ftp.uk.linux.org/pub/linux/Networking/netkit/netkit-rusers-%{version}.tar.gz
@@ -25,6 +25,7 @@
 Patch10: netkit-rusers-0.17-procps.patch
 Patch11: netkit-rusers-0.17-rup-stack.patch
 Patch12: netkit-rusers-0.17-bigendian.patch
+Patch13: netkit-rusers-0.17-return.patch
 Buildroot: %{_tmppath}/%{name}-root
 BuildRequires: procps libselinux-devel
 
@@ -68,6 +69,7 @@
 %patch10 -p1 -b .procps
 %patch11 -p1 -b .rup-stack
 %patch12 -p1 -b .bigendian
+%patch13 -p1 -b .return
 
 %build
 cat > MCONFIG <<EOF
@@ -140,6 +142,9 @@
 %config /etc/rc.d/init.d/rstatd
 
 %changelog
+* Tue Mar 21 2006 Phil Knirsch <pknirsch at redhat.com> - 0.17-46
+- Included fix for correct return values for rup (#177419)
+
 * Fri Feb 10 2006 Jesse Keating <jkeating at redhat.com> - 0.17-45.2.1
 - bump again for double-long bug on ppc(64)
 




More information about the fedora-cvs-commits mailing list