diff options
| author | Ton Voon <tonvoon@users.sourceforge.net> | 2004-11-12 00:49:51 +0000 |
|---|---|---|
| committer | Ton Voon <tonvoon@users.sourceforge.net> | 2004-11-12 00:49:51 +0000 |
| commit | fbf1e60f477460205c2002bb34b87f9e1e3b0faf (patch) | |
| tree | 96d568de54259a8b1f8e6a88dbb533037ef730e5 /lib/realloc.c | |
| parent | dbe8fb585697e3a7c073cef083ff2fb027b76968 (diff) | |
| download | monitoring-plugins-fbf1e60f477460205c2002bb34b87f9e1e3b0faf.tar.gz | |
Update to using coreutils 5.2.1 libraries and snprintf.c from samba 3.0.8
git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@895 f882894a-f735-0410-b71e-b25c423dba1c
Diffstat (limited to 'lib/realloc.c')
| -rw-r--r-- | lib/realloc.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/lib/realloc.c b/lib/realloc.c index d0d3e4ab..ccbf9913 100644 --- a/lib/realloc.c +++ b/lib/realloc.c | |||
| @@ -1,5 +1,5 @@ | |||
| 1 | /* Work around bug on some systems where realloc (NULL, 0) fails. | 1 | /* Work around bug on some systems where realloc (NULL, 0) fails. |
| 2 | Copyright (C) 1997 Free Software Foundation, Inc. | 2 | Copyright (C) 1997, 2003 Free Software Foundation, Inc. |
| 3 | 3 | ||
| 4 | This program is free software; you can redistribute it and/or modify | 4 | This program is free software; you can redistribute it and/or modify |
| 5 | it under the terms of the GNU General Public License as published by | 5 | it under the terms of the GNU General Public License as published by |
| @@ -22,19 +22,14 @@ | |||
| 22 | #endif | 22 | #endif |
| 23 | #undef realloc | 23 | #undef realloc |
| 24 | 24 | ||
| 25 | #include <sys/types.h> | 25 | #include <stdlib.h> |
| 26 | |||
| 27 | char *malloc (); | ||
| 28 | char *realloc (); | ||
| 29 | 26 | ||
| 30 | /* Change the size of an allocated block of memory P to N bytes, | 27 | /* Change the size of an allocated block of memory P to N bytes, |
| 31 | with error checking. If N is zero, change it to 1. If P is NULL, | 28 | with error checking. If N is zero, change it to 1. If P is NULL, |
| 32 | use malloc. */ | 29 | use malloc. */ |
| 33 | 30 | ||
| 34 | char * | 31 | void * |
| 35 | rpl_realloc (p, n) | 32 | rpl_realloc (void *p, size_t n) |
| 36 | char *p; | ||
| 37 | size_t n; | ||
| 38 | { | 33 | { |
| 39 | if (n == 0) | 34 | if (n == 0) |
| 40 | n = 1; | 35 | n = 1; |
