]> git.ipfire.org Git - people/arne_f/ipfire-3.x.git/blob - iputils/patches/iputils-s20071127-output.patch
Change file layout of the makefiles.
[people/arne_f/ipfire-3.x.git] / iputils / patches / iputils-s20071127-output.patch
1 diff -up iputils-s20071127/ping_common.c.output iputils-s20071127/ping_common.c
2 --- iputils-s20071127/ping_common.c.output 2008-02-26 14:12:02.000000000 +0100
3 +++ iputils-s20071127/ping_common.c 2008-02-26 14:24:34.000000000 +0100
4 @@ -791,8 +791,10 @@ static long llsqrt(long long a)
5 */
6 void finish(void)
7 {
8 - struct timeval tv = cur_time;
9 + struct timeval tv;
10 + char *comma = "";
11
12 + gettimeofday(&tv, NULL);
13 tvsub(&tv, &start_time);
14
15 putchar('\n');
16 @@ -827,12 +829,15 @@ void finish(void)
17 (long)tmax/1000, (long)tmax%1000,
18 (long)tmdev/1000, (long)tmdev%1000
19 );
20 + comma = ", ";
21 + }
22 + if (pipesize > 1) {
23 + printf("%spipe %d", comma, pipesize);
24 + comma = ", ";
25 }
26 - if (pipesize > 1)
27 - printf(", pipe %d", pipesize);
28 if (ntransmitted > 1 && nreceived && (!interval || (options&(F_FLOOD|F_ADAPTIVE)))) {
29 int ipg = (1000000*(long long)tv.tv_sec+tv.tv_usec)/(ntransmitted-1);
30 - printf(", ipg/ewma %d.%03d/%d.%03d ms",
31 + printf("%sipg/ewma %d.%03d/%d.%03d ms", comma,
32 ipg/1000, ipg%1000, rtt/8000, (rtt/8)%1000);
33 }
34 putchar('\n');