3 ms·
> Allocating zero bytes can fail (with dumb C libraries). They might not be dumb; they might be forced into it to maintain compatibility with buggy programs a
by pcwalton 11y ago
> Allocating zero bytes can fail (with dumb C libraries).
They might not be dumb; they might be forced into it to maintain compatibility with buggy programs and/or configure scripts (e.g. [1]).
[1]: http://www.openwall.com/lists/musl/2013/01/15/1 http://www.openwall.com/lists/musl/2013/01/15/1
- cperciva 11y agoUnfortunately, as I wrote in the commit message which spawned this thread, this just encourages people to write more buggy programs.
- pcwalton 11y agoOr, more likely, it just encourages customers to abandon your alternative C library in favor of glibc to avoid breaking configure scripts (which is what forced musl's hand). I definitely think you're right in principle, but I can't blame musl's author for bowing to market pressure any more than I can blame Intel for sticking to x86 backwards compatibility.