From owner-freebsd-bugs Sat Aug 21 9: 0: 8 1999 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 21610150FB for ; Sat, 21 Aug 1999 09:00:02 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id JAA28516; Sat, 21 Aug 1999 09:00:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: by hub.freebsd.org (Postfix, from userid 32767) id 63EB514F10; Sat, 21 Aug 1999 08:57:24 -0700 (PDT) Message-Id: <19990821155724.63EB514F10@hub.freebsd.org> Date: Sat, 21 Aug 1999 08:57:24 -0700 (PDT) From: thomma@slip.net To: freebsd-gnats-submit@freebsd.org X-Send-Pr-Version: www-1.0 Subject: bin/13292: Ping -s does not work Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 13292 >Category: bin >Synopsis: Ping -s does not work >Confidential: no >Severity: serious >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sat Aug 21 09:00:01 PDT 1999 >Closed-Date: >Last-Modified: >Originator: Tamiji Homma >Release: 4.0-current >Organization: >Environment: FreeBSD snoopy.pochi.com 4.0-CURRENT FreeBSD 4.0-CURRENT #73: Wed Aug 11 22:31:31 PDT 1999 root@snoopy.pochi.com:/usr/src/sys/compile/SNOOPY i386 >Description: ping command generates bad check sum for odd size icmp data. This is caused by EGCS optimizer bug. >How-To-Repeat: # ping -s 57 localhost >Fix: Compiled with -O0 or apply following patch Index: ping.c =================================================================== RCS file: /usr/home/ncvs/src/sbin/ping/ping.c,v retrieving revision 1.44 diff -c -r1.44 ping.c *** ping.c 1999/05/07 14:38:48 1.44 --- ping.c 1999/08/21 15:55:39 *************** *** 944,949 **** --- 944,950 ---- /* mop up an odd byte, if necessary */ if (nleft == 1) { *(u_char *)(&answer) = *(u_char *)w ; + *((u_char *)(&answer) + 1) = 0; sum += answer; } >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message