From owner-freebsd-current Tue Nov 16 10:26:53 1999 Delivered-To: freebsd-current@freebsd.org Received: from enst.enst.fr (enst.enst.fr [137.194.2.16]) by hub.freebsd.org (Postfix) with ESMTP id 2C64E151F5; Tue, 16 Nov 1999 10:26:33 -0800 (PST) (envelope-from beyssac@enst.fr) Received: from bofh.enst.fr (bofh-2.enst.fr [137.194.2.37]) by enst.enst.fr (8.9.1a/8.9.1) with ESMTP id TAA08775; Tue, 16 Nov 1999 19:26:31 +0100 (MET) Received: by bofh.enst.fr (Postfix, from userid 12426) id 9854BD226; Tue, 16 Nov 1999 19:26:30 +0100 (CET) Message-ID: <19991116192628.A83154@enst.fr> Date: Tue, 16 Nov 1999 19:26:28 +0100 From: Pierre Beyssac To: Kris Kennaway Cc: freebsd-current@FreeBSD.ORG Subject: Re: egcs -O breaks ping.c:in_cksum() References: <19991116002921.A39215@fasterix.frmug.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.93.2i In-Reply-To: ; from Kris Kennaway on Mon, Nov 15, 1999 at 05:59:23PM -0800 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, Nov 15, 1999 at 05:59:23PM -0800, Kris Kennaway wrote: > On Tue, 16 Nov 1999, Pierre Beyssac wrote: > > I've checked, the answer is no: apparently, in_cksum() in routed/rdisc.c > > is only called in two places, both with an even size. > > Can it hurt to pre-emptively fix it anyway in case some future change > pulls the rug out from underneath? We could, but since the danger is purely theoretical for now (and probably will stay that way forever), I don't see any advantage in cluttering up the code. Since routed is sometimes sync'ed from external sources, it would only make life harder for the people doing the merges. Plus, everyone steals in_cksum from ping, not from routed (at least, that's what I do :-) Since in_cksum is used in several places (there's another optimized copy in libstand), a cleaner solution would be to put it in some library. -- Pierre Beyssac pb@enst.fr To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message