Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- libc - <b>xrealloc</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
xrealloc
========

Syntax
------

     #include <stdlib.h>
     
     void *xrealloc(void *ptr, size_t size);

Description
-----------

This function is just like `realloc' (realloc:.), except that if   
there is no more memory, it prints an error message and exits.  It can
also properly handle PTR being `NULL'.

Return Value
------------

A pointer to a possibly new block.

Example
-------

     char *buf;
     buf = (char *)xrealloc(buf, new_size);


See Also: realloc

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson