Is it guaranteed to be safe to perform memcpy(0,0,0)?
I am not so well-versed in the C standard, so please bear with me. I would like to know if it is guaranteed, by the standard, that memcpy(0,0,0) is safe. The only restriction I could find is that if the memory regions overlap, then the behavior is undefined... But can we consider that the memory regions overlap here ? I have a draft version of the C standard (ISO/IEC 9899:1999), and it has some fun things to say about that call. For starters, it mentions (§7.21.1/2) in regards to memcpy that Where an argument declared as size_t n specifies the length of the array for a function, n can have the