3 ms·
malloc(0) is implementation-defined: https://port70.net/~nsz/c/c11/n1570.html#7.22.3p1 https://port70.net/~nsz/c/c11/n1570.html#7.22.3p1 One might, I suppose,
by tom_ 9y ago
malloc(0) is implementation-defined: https://port70.net/~nsz/c/c11/n1570.html#7.22.3p1 https://port70.net/~nsz/c/c11/n1570.html#7.22.3p1
One might, I suppose, decide that new_image will be exactly equivalent to the system malloc in this respect, in which case malloc(0) should be called when appropriate.