diff options
author | Jeremy Allison <jra@samba.org> | 2001-08-19 17:54:10 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-08-19 17:54:10 +0000 |
commit | e077bcada95f8c7d788d60fa37e9e483ad6f7665 (patch) | |
tree | eba385ebddb9dc8a1808cc245b6b9d2ff4f0d7ed | |
parent | e47cac8db4b212cbd14110ae379a95abd31f8e54 (diff) | |
download | samba-e077bcada95f8c7d788d60fa37e9e483ad6f7665.tar.gz samba-e077bcada95f8c7d788d60fa37e9e483ad6f7665.tar.bz2 samba-e077bcada95f8c7d788d60fa37e9e483ad6f7665.zip |
Realloc fixes.
Jeremy.
(This used to be commit 560ae7615eb8eca2c872b1196ce0b9534bf8ad76)
-rw-r--r-- | source3/groupdb/groupfile.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source3/groupdb/groupfile.c b/source3/groupdb/groupfile.c index ba9027b4f6..124da186fa 100644 --- a/source3/groupdb/groupfile.c +++ b/source3/groupdb/groupfile.c @@ -131,8 +131,9 @@ static char *get_group_members(char *p, int *num_mem, DOMAIN_GRP_MEMBER **member DOMAIN_GRP_MEMBER *mbrs; mbrs = Realloc((*members), ((*num_mem)+1) * sizeof(DOMAIN_GRP_MEMBER)); - if (mbrs == NULL) - { + if (mbrs == NULL) { + if (*members) + free(*members); return NULL; } else (*members) = mbrs; |