diff options
| author | Warner Losh <imp@FreeBSD.org> | 1998-09-14 20:34:34 +0000 | 
|---|---|---|
| committer | Warner Losh <imp@FreeBSD.org> | 1998-09-14 20:34:34 +0000 | 
| commit | 94ad719cf47118069c9d840583e10ee17b5dfe50 (patch) | |
| tree | 1cb89d88bd80c750c1346595db3af7715d4d5c26 /lib/libc/stdlib/reallocf.c | |
| parent | d6e5b04f9960ebfad47eb5442fb7acd671a0c58d (diff) | |
Notes
Diffstat (limited to 'lib/libc/stdlib/reallocf.c')
| -rw-r--r-- | lib/libc/stdlib/reallocf.c | 12 | 
1 files changed, 12 insertions, 0 deletions
| diff --git a/lib/libc/stdlib/reallocf.c b/lib/libc/stdlib/reallocf.c new file mode 100644 index 000000000000..728acc9af579 --- /dev/null +++ b/lib/libc/stdlib/reallocf.c @@ -0,0 +1,12 @@ +#include <stdlib.h> + +void * +reallocf(void *ptr, size_t size) +{ +    void *nptr; + +    nptr = realloc(ptr, size); +    if (!nptr && ptr) +        free(ptr); +    return (nptr); +} | 
