On Tue, 8 Dec 2009, Markus Armbruster wrote: > malc <av1...@comtv.ru> writes: >
[..snip..] > glibc frees since 1999. From glibc/ChangeLog.10: > > 1999-04-28 Andreas Jaeger <a...@arthur.rhein-neckar.de> > > * malloc/malloc.c (REALLOC_ZERO_BYTES_FREES): Define it to follow > ISO C9x and Unix98. Problem is - this is NOT what C9x where x > 0 says. > > > How anyone can use this interface and it's implementations portably > > or "sanely" is beyond me. > > > > Do read the discussion the linked above. > > Yes, malloc() & friends are tricky for portable programs. And yes, > bugs do creep into international standards. > > But since we wrap malloc() & friends anyway, we can pick a variant of > the semantics we like. No need to punish ourselves with wrappers that > are hard to use, just because the wrappees are hard to use. > > Anyway, I figure this thread has wandered off topic for this list. > -- mailto:av1...@comtv.ru