From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from postman.osf.org ([130.105.1.152]) by hawkwind.utcs.toronto.edu with SMTP id <2223>; Tue, 21 Sep 1993 10:17:48 -0400 Received: from sulphur.osf.org by postman.osf.org (5.64+/OSF 1.0) id AA03763; Tue, 21 Sep 93 10:17:28 -0400 Received: by sulphur.osf.org (1.37.109.4/4.7) id AA12232; Tue, 21 Sep 93 10:17:54 -0400 Date: Tue, 21 Sep 1993 10:17:54 -0400 From: rsalz@osf.org Message-Id: <9309211417.AA12232@sulphur.osf.org> To: culliton@srg.af.mil, rc@hawkwind.utcs.toronto.edu Subject: Re: A potentially useful patch I absolutely hate it when people use #ifdef to break up C flow of control statements. This seems cleaner and fits Byron's coding style (using !p for p == NULL -- ick!): extern void *erealloc(void *p, SIZE_T n) { extern void *realloc(void *, SIZE_T); + #ifdef BROKENREALLOC + if (p == NULL) + return ealloc(n); + #endif if ((p = realloc(p, n)) == NULL) { uerror("realloc"); rc_exit(1); } return p; } /r$