Avi Kivity wrote: > Only if you allocate using POSIX malloc(). If you allocate using a > function that is defined to return a valid pointer for zero length > allocations, you're happy.
Wouldnt it be better to, rather than use a qemu_malloc() that is utterly counterintuitive in that it has no way to report failure, and behaves in ways people dont expect, to use normal malloc() and never pass it 0 ? Seriously, who does that anyway? why call malloc when you dont want the space? so you can use realloc? 99.99% of the time realloc() is the Wrong Solution(tm). stick to what people know, and LART them for misuse of it if necessary. (Just my 2p) -Ian