Added realloc() implementation that behaves like free() when size==0 - consistently on all platforms, in contrast to standard realloc()