Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Oct 2001 09:48:19 +1000
From:      Darren Reed <darrenr@reed.wattle.id.au>
To:        peter@wemm.org (Peter Wemm)
Cc:        astouffer@adelphia.net, freebsd-alpha@FreeBSD.ORG, darrenr@reed.wattle.id.au
Subject:   Re: ipfilter bug (was: Re: compiler bugs? )
Message-ID:  <200110242348.JAA06267@avalon.reed.wattle.id.au>
In-Reply-To: <20011024164534.857FF39F3@overcee.netplex.com.au> from Peter Wemm at "Oct 24, 1 09:45:34 am"

next in thread | previous in thread | raw e-mail | index | archive | help
Thanks Peter!

Darren

In some email I received from Peter Wemm, sie wrote:
> Adam Stouffer wrote:
> > I'm trying to get ipfilter compiled so this box can be made into a 
> > firewall. After getting the latest ipfilter sources (3.4.21) I follow the 
> > instructions and type 'make freebsd4' after a minute or so it stops with 
> > this error:
> > 
> > cc1: warnings being treated as errors
> > ../../ip_auth.c: In function `fr_auth_ioctl':
> > ../../ip_auth.c:344: warning: comparison is always false due to limited 
> > range of data type
> > *** Error code 1
> > 
> > Line 344 shows:
> > 
> > 	if (cmd == SIOCRMAFR) {
> > 
> > After emailing Darren Reed he says its because of a compiler bug. Is this 
> > true? 4.4 release also ships with the same 2.95.3 version of gcc. Also why 
> > is ipfilter not included in the ports tree? Thanks.
> 
> Nope. It is a code bug in ipfilter:
> 
> int fr_auth_ioctl(data, mode, cmd, fr, frptr)
> caddr_t data;
> int mode;
> #if defined(__NetBSD__) || defined(__OpenBSD__) || (FreeBSD_version >= 300003)
>                                                   ^^^^^^^^^^^^^^^^^^^
> u_long cmd;
> #else
> int cmd;
> #endif
> 
> It is __FreeBSD_version, not FreeBSD_version.  This means that it is using
> the 'int cmd' form, which is not large enough to represent the SIOCRMAFR
> ioctl value.
> 
> > Adam
> 
> Cheers,
> -Peter
> --
> Peter Wemm - peter@FreeBSD.org; peter@yahoo-inc.com; peter@netplex.com.au
> "All of this is for nothing if we don't go to the stars" - JMS/B5
> 
> 
> 


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-alpha" in the body of the message




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