Remove unnecessary realloc