malloc(0) zero-size allocation returns NULL or non-null by implementation
Goal I need to allocate a zero-sized block with malloc(0) in portable C code and handle the result correctly across different C library implementations. Constraints The C standard leaves malloc(0) implementation-defined: it may return NULL or a pointer to a zero-size object that must not be dereferenced. There is no standard feature-test macro to select the