diff options
author | Andrew Tridgell <tridge@samba.org> | 2004-12-03 06:42:06 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:06:19 -0500 |
commit | e5ce904ddbd6175ba86ed827bf096b76b11b5511 (patch) | |
tree | 722b04d001e9b26bb47b2480fef13699a0366667 /source4/lib/util.c | |
parent | 7dcfd94f817d1c12a14704cbb96604dc3074aa2e (diff) | |
download | samba-e5ce904ddbd6175ba86ed827bf096b76b11b5511.tar.gz samba-e5ce904ddbd6175ba86ed827bf096b76b11b5511.tar.bz2 samba-e5ce904ddbd6175ba86ed827bf096b76b11b5511.zip |
r4054: got rid of Realloc(), replacing it with the type safe macro realloc_p()
(This used to be commit b0f6e21481745d1b2ced28d9ed6f09f6ffd99562)
Diffstat (limited to 'source4/lib/util.c')
-rw-r--r-- | source4/lib/util.c | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/source4/lib/util.c b/source4/lib/util.c index 2d149e6e3d..ac5124840e 100644 --- a/source4/lib/util.c +++ b/source4/lib/util.c @@ -216,31 +216,6 @@ void become_daemon(BOOL Fork) /**************************************************************************** - Expand a pointer to be a particular size. -****************************************************************************/ - -void *Realloc(void *p,size_t size) -{ - void *ret=NULL; - - if (size == 0) { - SAFE_FREE(p); - DEBUG(5,("Realloc asked for 0 bytes\n")); - return NULL; - } - - if (!p) - ret = (void *)malloc(size); - else - ret = (void *)realloc(p,size); - - if (!ret) - DEBUG(0,("Memory allocation error: failed to expand to %d bytes\n",(int)size)); - - return(ret); -} - -/**************************************************************************** Free memory, checks for NULL. Use directly SAFE_FREE() Exists only because we need to pass a function pointer somewhere --SSS |