From owner-freebsd-bugs Wed Jun 25 15:00:05 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id PAA16587 for bugs-outgoing; Wed, 25 Jun 1997 15:00:05 -0700 (PDT) Received: from www.destek.net (ns2.destek.net [192.156.97.61]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id PAA16582 for ; Wed, 25 Jun 1997 15:00:02 -0700 (PDT) Received: from synergy.Destek.Net (root@synergy.destek.net [192.156.97.240]) by www.destek.net (8.8.5/8.8.4) with ESMTP id RAA20823 for ; Wed, 25 Jun 1997 17:59:57 -0400 (EDT) Received: from [[UNIX: localhost]] ([[UNIX: localhost]]) by synergy.Destek.Net (8.8.4/8.7.3) with SMTP id RAA09369 for ; Wed, 25 Jun 1997 17:59:56 -0400 (EDT) Message-Id: <199706252159.RAA09369@synergy.Destek.Net> X-Authentication-Warning: synergy.Destek.Net: [[UNIX: localhost]] didn't use HELO protocol X-Mailer: exmh version 2.0gamma 1/24/96 X-Uri: X-Face: ">4>,~~_HqlZ,c;!7K60$oLXj\whr`|V-}}cog.gO2Q^/CC[E>,Ez*N0C#)CYY8J\]APjp6 ~)]fwuyFuTXe{7z'Zgt,=+chm*DPh([b^SBn.^jXxI/oT=_L:ws!rF{y[99PV$-~#@dhtc3Y*fK!so 4g:PM0)hs0*9)TsHWfN)=d0P_| From: Marc Evans To: freebsd-bugs@freebsd.org Subject: tftpd bug Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Wed, 25 Jun 1997 17:59:53 -0400 Sender: owner-bugs@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Hello - It appears that there is a long-standing bug in tftp, in that files greater then 16M bytes fail to transfer. A closer look at the issue appears to reveal that the problem is caused by /usr/include/arpa/tftp.h which with the following modifications may work better (e.g., I haven't yet tested this): diff -c /usr/include/arpa/tftp* *** tftp.h Wed Jun 25 17:28:20 1997 --- tftp.h.orig Wed Jun 25 17:28:17 1997 *************** *** 52,60 **** #define ERROR 05 /* error code */ struct tftphdr { ! unsigned short th_opcode; /* packet type */ ! unsigned short th_block; /* block # */ ! char th_data[1]; /* data or error string */ }; #define th_code th_block /* error code overlay on tu_block */ --- 52,60 ---- #define ERROR 05 /* error code */ struct tftphdr { ! short th_opcode; /* packet type */ ! short th_block; /* block # */ ! char th_data[1]; /* data or error string */ }; #define th_code th_block /* error code overlay on tu_block */ In other words, there appears to be a wrap-around bug due to the datatype being used. - Marc =============================================================================== Marc Evans WB1GRH The Destek Networking Group E-Mail: Marc@Destek.NET One Indian Head Plaza URL: http://WWW.Destek.NET/~marc Nashua, NH, USA 03060 MIME-1.0 & Enriched-Text mail accepted 603 594 9630 (V) 598 8864 (F) PGP-2.6 key available upon request WAN & Internet Services PGP-2.6 Fingerprint: 20 7C A2 DB 17 B2 21 80 47 AA B9 CD D9 DE 31 CC The XFree86[tm] Project, Inc. Industry Liason ===============================================================================