Xref: utzoo comp.unix.xenix:2600 comp.sources.d:2392
Path: utzoo!attcan!uunet!husc6!cs.utexas.edu!milano!bigtex!james
From: james@bigtex.uucp (James Van Artsdalen)
Newsgroups: comp.unix.xenix,comp.sources.d
Subject: Re: tgetent core dump on sco xenix
Keywords: tgetent,core dump,sco,xenix,large model
Message-ID: <3222@bigtex.uucp>
Date: 4 Jul 88 02:01:27 GMT
References: <54@libove.UUCP> <701@nod2sco>
Reply-To: james@bigtex.UUCP (James Van Artsdalen)
Distribution: comp
Organization: F.B.N. Software, Austin TX
Lines: 17

IN article <701@nod2sco>, rosso@sco.COM (Ross Oliver) wrote:
> Here are a few tips to avoid problems like this in large-model
> 286 programs:

>     - Declare your functions' return values.
>     - Don't use "0" to mean NULL ( i.e. (char *)0 ).

This last statement is incorrect, or rather, evidence of a broken
compiler.

C requires that the integer constant 0 be assignable to *any* pointer
type.  C also requires that any pointer type may be compared with the
integer constant 0.  If the Xenix compiler requires that the integer
constant 0 be cast to a pointer type first, it is broken.
-- 
James R. Van Artsdalen   ...!ut-sally!utastro!bigtex!james   "Live Free or Die"
Home: 512-346-2444 Work: 328-0282; 110 Wild Basin Rd. Ste #230, Austin TX 78746