*BSD News Article 67072


Return to BSD News archive

Path: euryale.cc.adfa.oz.au!newshost.anu.edu.au!harbinger.cc.monash.edu.au!news.rmit.EDU.AU!news.unimelb.EDU.AU!munnari.OZ.AU!metro!metro!asstdc.scgt.oz.au!nsw.news.telstra.net!act.news.telstra.net!vic.news.telstra.net!news.mira.net.au!inquo!in-news.erinet.com!izzy.net!aanews.merit.net!imci3!imci4!newsfeed.internetmci.com!tank.news.pipex.net!pipex!dispatch.news.demon.net!demon!awfulhak.demon.co.uk!awfulhak.demon.co.uk!awfulhak.demon.co.uk!not-for-mail
From: brian@awfulhak.demon.co.uk (Brian Somers)
Newsgroups: comp.unix.bsd.freebsd.misc
Subject: Re: /usr/include/unistd.h (V2.0.5) "dead2"
Date: 26 Apr 1996 10:17:25 +0100
Organization: Coverform Ltd.
Lines: 55
Message-ID: <4lq4b5$h2@anorak.coverform.lan>
References: <4jpda9$fb3@saluki-news.wham.siu.edu> <4k9iir$2ac@anorak.coverform.lan> <4li9v6$2is0@info4.rus.uni-stuttgart.de>
X-NNTP-Posting-Host: awfulhak.demon.co.uk
X-Newsreader: TIN [version 1.2 PL2]

Jens Schweikhardt (schweikh@itosun.ito.uni-stuttgart.de) wrote:
: In article <4k9iir$2ac@anorak.coverform.lan>,
: Brian Somers <brian@awfulhak.demon.co.uk> wrote:
: +Jim Dutton (jimd@dutton2.it.siu.edu) wrote:
: +: What is the fix for the apparent misdeclartion in unisthd.h at
: +: line 53 which looks like:
: +
: +: 	 _exit __P((int)) __dead2;
: +
: +This isn't a mis-decl under gcc (see sys/cdefs.h).  If you're using another
: +compiler, modify sys/cdefs.h so that it has something like
: +
: +#ifndef __dead
: +#define __dead
: +#endif
: +#ifndef __dead2
: +#define __dead2
: +#endif
: +#ifndef __pure
: +#define __pure
: +#endif
: +#ifndef __pure2
: +#define __pure2
: +#endif
: +
: +at the bottom of the file (before the final #endif).  If you are using
: +another compiler, I suspect that this problem is only the first of many !

: Recently I ran into this, uhm, uglyness.
: I am using lclint 2.0 to lint my programs.
: Any source file including unistd.h will
: make lclint choke and stop with an
: unrecoverable parse error. I decided to delete
: the __dead* code from unistd.h.

: What will I break by this?

: Inquiring minds want to know...

: 	Bye, Jens
: -- 
: SIGSIG -- signature too long (core dumped)

Nothing will break, but a particularily pedantic compiler will produce
warnings under certain circumstances when you write the following piece
of (incorrect IMHO) code:

int main( int, char *[] )
{
	exit(0);
}

--
Brian <brian@awfulhak.demon.co.uk>
Don't _EVER_ lose your sense of humour....