Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 14 Oct 1995 18:48:31 +0100 (MET)
From:      J Wunsch <j@uriah.heep.sax.de>
To:        freebsd-hackers@freebsd.org
Subject:   Re: lint
Message-ID:  <199510141748.SAA11040@uriah.heep.sax.de>
In-Reply-To: <199510141407.AAA17454@godzilla.zeta.org.au> from "Bruce Evans" at Oct 15, 95 00:07:57 am

next in thread | previous in thread | raw e-mail | index | archive | help
As Bruce Evans wrote:
> 
> There is a more serious conflict between <ctype.h> and both <stddef.h>
> and <stdlib.h>.  The following doesn't compile if either _ANSI_SOURCE or
> _POSIX_SOURCE is defined:
> 
> 	#include <stddef.h>
> 	#include <stdlib.h>
> 
> All these bugs should be fixed by using a different ifdef guard for
> wchar_t and rune_t.

Ok.

> >. The ANSI-violating definitions for fgets() (second parameter must be
> >  int, not size_t) and ftell() (parameter is not const); i'm about to
> >  change them.
> 
> It's interesting that these bugs have been around for so long.  The
> first but not the second is fixed in 4.4lite2.

They are benign, and only become apparent by manually declaring the
functions according to the ANSI standard.  Jochen Pohl's llib-lstdc
does this.


The newly-built lint buried another bogon out of the depths of the
header mishmash: we've got a name clash for struct pmap!  It's
declared inside the VM stuff as a "page map" structure
(machine/pmap.h), and inside the RPC library as a "portmapper"
structure.  The header files for both are required to have a complete
set of header files describing the libc.

I've quickly solved the clash by renaming pmap into _pmap inside
<machine/pmap.h>, which required the change from "struct pmap" into
"pmap_t" inside the definition of struct vmspace in <vm/vm.h>.  I'm
not sure whether this is the most optimal fix however.

-- 
cheers, J"org

joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)



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