ANSI C free() NULL test "was free (NULL)";
Andrew Hume
andrew at alice.UUCP
Wed May 23 00:11:42 AEST 1990
the badness of allowing free(NULL) is not so much that it encourages sloppy
programming but rather its tie with the bad decision to make a
special case out of malloc(0) which ought to have meant what every manual page
until recently said it meant: a pointer to at least 0 bytes of memory.
no need for a calculus of zero sized objects; just follow the man page.
still, who am i to complain; at least the committee got noalias right.
More information about the Comp.lang.c
mailing list