> The second one: in tru64 malloc/calloc/realloc of zero bytes returns > a NULL ptr (quite logical, in a way: you couldn't put anything in a > memory block of zero bytes...). I guess one could be fancier and > add a probe for this feature in Configure.pl, but I was feeling lazy.
A third alternative would be to investigate why would anyone be allocating zero bytes; this might indicate a more serious error, depending on what the caller was expecting/intending and what were they going to do with the result.