work in progress: realloc