- fix inconsistent behaviour of ping (#360881)
This commit is contained in:
parent
403b7c0bdb
commit
25380c1c5b
34
iputils-20071127-output.patch
Normal file
34
iputils-20071127-output.patch
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
diff -up iputils-s20071127/ping_common.c.output iputils-s20071127/ping_common.c
|
||||||
|
--- iputils-s20071127/ping_common.c.output 2008-02-26 14:12:02.000000000 +0100
|
||||||
|
+++ iputils-s20071127/ping_common.c 2008-02-26 14:24:34.000000000 +0100
|
||||||
|
@@ -791,8 +791,10 @@ static long llsqrt(long long a)
|
||||||
|
*/
|
||||||
|
void finish(void)
|
||||||
|
{
|
||||||
|
- struct timeval tv = cur_time;
|
||||||
|
+ struct timeval tv;
|
||||||
|
+ char *comma = "";
|
||||||
|
|
||||||
|
+ gettimeofday(&tv, NULL);
|
||||||
|
tvsub(&tv, &start_time);
|
||||||
|
|
||||||
|
putchar('\n');
|
||||||
|
@@ -827,12 +829,15 @@ void finish(void)
|
||||||
|
(long)tmax/1000, (long)tmax%1000,
|
||||||
|
(long)tmdev/1000, (long)tmdev%1000
|
||||||
|
);
|
||||||
|
+ comma = ", ";
|
||||||
|
+ }
|
||||||
|
+ if (pipesize > 1) {
|
||||||
|
+ printf("%spipe %d", comma, pipesize);
|
||||||
|
+ comma = ", ";
|
||||||
|
}
|
||||||
|
- if (pipesize > 1)
|
||||||
|
- printf(", pipe %d", pipesize);
|
||||||
|
if (ntransmitted > 1 && nreceived && (!interval || (options&(F_FLOOD|F_ADAPTIVE)))) {
|
||||||
|
int ipg = (1000000*(long long)tv.tv_sec+tv.tv_usec)/(ntransmitted-1);
|
||||||
|
- printf(", ipg/ewma %d.%03d/%d.%03d ms",
|
||||||
|
+ printf("%sipg/ewma %d.%03d/%d.%03d ms", comma,
|
||||||
|
ipg/1000, ipg%1000, rtt/8000, (rtt/8)%1000);
|
||||||
|
}
|
||||||
|
putchar('\n');
|
@ -1,7 +1,7 @@
|
|||||||
Summary: Network monitoring tools including ping
|
Summary: Network monitoring tools including ping
|
||||||
Name: iputils
|
Name: iputils
|
||||||
Version: 20071127
|
Version: 20071127
|
||||||
Release: 1%{?dist}
|
Release: 2%{?dist}
|
||||||
License: BSD
|
License: BSD
|
||||||
URL: http://www.skbuff.net/iputils
|
URL: http://www.skbuff.net/iputils
|
||||||
Group: System Environment/Daemons
|
Group: System Environment/Daemons
|
||||||
@ -21,6 +21,7 @@ Patch26: iputils-20070202-idn.patch
|
|||||||
Patch27: iputils-20070202-open-max.patch
|
Patch27: iputils-20070202-open-max.patch
|
||||||
Patch28: iputils-20070202-traffic_class.patch
|
Patch28: iputils-20070202-traffic_class.patch
|
||||||
Patch29: iputils-20070202-arping_timeout.patch
|
Patch29: iputils-20070202-arping_timeout.patch
|
||||||
|
Patch30: iputils-20071127-output.patch
|
||||||
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
BuildRequires: docbook-utils perl-SGMLSpm
|
BuildRequires: docbook-utils perl-SGMLSpm
|
||||||
@ -54,6 +55,7 @@ the target machine is alive and receiving network traffic.
|
|||||||
%patch27 -p1 -b .open-max
|
%patch27 -p1 -b .open-max
|
||||||
%patch28 -p1 -b .traffic_class
|
%patch28 -p1 -b .traffic_class
|
||||||
%patch29 -p1 -b .arping_timeout
|
%patch29 -p1 -b .arping_timeout
|
||||||
|
%patch30 -p1 -b .output
|
||||||
|
|
||||||
%build
|
%build
|
||||||
%ifarch s390 s390x
|
%ifarch s390 s390x
|
||||||
@ -154,6 +156,9 @@ rm -rf ${RPM_BUILD_ROOT}
|
|||||||
%{_sysconfdir}/rc.d/init.d/rdisc
|
%{_sysconfdir}/rc.d/init.d/rdisc
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Mar 25 2008 Martin Nagy <mnagy@redhat.com> - 20071127-2
|
||||||
|
- fix inconsistent behaviour of ping (#360881)
|
||||||
|
|
||||||
* Mon Feb 25 2008 Martin Nagy <mnagy@redhat.com> - 20071127-1
|
* Mon Feb 25 2008 Martin Nagy <mnagy@redhat.com> - 20071127-1
|
||||||
- update to new upstream version
|
- update to new upstream version
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user