xmalloc: Do not leak if underlying realloc is C99 compatible.
authorPaul Eggert <eggert@cs.ucla.edu>
Thu, 24 Mar 2011 20:10:38 +0000 (13:10 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Thu, 24 Mar 2011 20:11:11 +0000 (13:11 -0700)
commit84a1c646b281107213dcaa481b97e0fcba2ec589
tree45f1592ee1eafabe4f5abcdc01671edd67da5cf6
parent444f6d99e3786db042fd90bade4f1864e89ceb05
xmalloc: Do not leak if underlying realloc is C99 compatible.

* lib/xmalloc.c (xrealloc): If N is zero, call 'free' directly.
This avoids a leak on C99-based systems.  See
<http://lists.gnu.org/archive/html/bug-gnulib/2011-03/msg00243.html>.
ChangeLog
lib/xmalloc.c