Don't leak memory on failed realloc

realloc() doesn't free the original pointer on failure
No need for realloc on failure

No special need for realloc in this one failure case. No reallocs are
done on other failures and it most likely won't free any memory anyway.
Merge pull request #2 from sth/master

Realloc might leak memory on failure