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/param | |
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/param')
-rw-r--r-- | source4/param/loadparm.c | 4 | ||||
-rw-r--r-- | source4/param/params.c | 6 |
2 files changed, 4 insertions, 6 deletions
diff --git a/source4/param/loadparm.c b/source4/param/loadparm.c index 1d9553de3e..8975f066fa 100644 --- a/source4/param/loadparm.c +++ b/source4/param/loadparm.c @@ -1568,9 +1568,7 @@ static int add_a_service(const service *pservice, const char *name) if (i == iNumServices) { service **tsp; - tsp = (service **) Realloc(ServicePtrs, - sizeof(service *) * - num_to_alloc); + tsp = realloc_p(ServicePtrs, service *, num_to_alloc); if (!tsp) { DEBUG(0,("add_a_service: failed to enlarge ServicePtrs!\n")); diff --git a/source4/param/params.c b/source4/param/params.c index a31d8d1b60..1b5b02cfa3 100644 --- a/source4/param/params.c +++ b/source4/param/params.c @@ -239,7 +239,7 @@ static BOOL Section( myFILE *InFile, BOOL (*sfunc)(const char *) ) { char *tb; - tb = Realloc( bufr, bSize +BUFR_INC ); + tb = realloc_p(bufr, char, bSize + BUFR_INC); if( NULL == tb ) { DEBUG(0, ("%s Memory re-allocation failure.", func) ); @@ -336,7 +336,7 @@ static BOOL Parameter( myFILE *InFile, BOOL (*pfunc)(const char *, const char *) { char *tb; - tb = Realloc( bufr, bSize + BUFR_INC ); + tb = realloc_p( bufr, char, bSize + BUFR_INC ); if( NULL == tb ) { DEBUG(0, ("%s Memory re-allocation failure.", func) ); @@ -404,7 +404,7 @@ static BOOL Parameter( myFILE *InFile, BOOL (*pfunc)(const char *, const char *) { char *tb; - tb = Realloc( bufr, bSize + BUFR_INC ); + tb = realloc_p( bufr, char, bSize + BUFR_INC ); if( NULL == tb ) { DEBUG(0, ("%s Memory re-allocation failure.", func) ); |