Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 07 Apr 2021 18:43:04 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 254860] ping flood output incorrectly shows dot for dropped packet
Message-ID:  <bug-254860-227@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D254860

            Bug ID: 254860
           Summary: ping flood output incorrectly shows dot for dropped
                    packet
           Product: Base System
           Version: CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: bin
          Assignee: bugs@FreeBSD.org
          Reporter: jcaplan@blackberry.com

Created attachment 223903
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D223903&action=
=3Dedit
proposed patch

Overview
--------

The output of the ping with '-f' option always contains one dot symbol
indicating that one packet has been dropped even all ECHO_REPLY have been
received successfully and there is 0.0% packet loss actually.

This is because the final '\b' written in pr_pack() is ignored when
putchar('\n') gets called in finish().

Attached solution diff makes sure in pr_pack() that the DOT is overwritten =
with
a space.

Steps to Reproduce
------------------
$ sudo ping -f -c1 localhost
PING6(56=3D40+8+8 bytes) ::1 --> ::1
.
--- localhost ping6 statistics ---
1 packets transmitted, 1 packets received, 0.0% packet loss
round-trip min/avg/max/std-dev =3D 0.460/0.460/0.460/0.000 ms


Actual Results
--------------
There is a dot in the middle line:
PING6(56=3D40+8+8 bytes) ::1 --> ::1
.
--- localhost ping6 statistics ---


Expected Results
----------------
No dot.

Build Date & Hardware
---------------------
FreeBSD bsd-vbox 13.0-CURRENT FreeBSD 13.0-CURRENT #0 r368820: Tue Jan  5
17:30:19 EST 2021=20=20=20=20
jcaplan@bsd-vbox:/usr/obj/usr/src-head/amd64.amd64/sys/GENERIC  amd64

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-254860-227>