summaryrefslogtreecommitdiff
path: root/source3/passdb
diff options
context:
space:
mode:
Diffstat (limited to 'source3/passdb')
-rw-r--r--source3/passdb/pdb_ldap.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c
index 1fe5212d57..8429d50b38 100644
--- a/source3/passdb/pdb_ldap.c
+++ b/source3/passdb/pdb_ldap.c
@@ -3076,7 +3076,6 @@ static NTSTATUS ldapsam_enum_group_mapping(struct pdb_methods *methods,
BOOL unix_only)
{
GROUP_MAP map;
- GROUP_MAP *mapt;
size_t entries = 0;
*p_num_entries = 0;
@@ -3101,17 +3100,14 @@ static NTSTATUS ldapsam_enum_group_mapping(struct pdb_methods *methods,
continue;
}
- mapt=SMB_REALLOC_ARRAY((*pp_rmap), GROUP_MAP, entries+1);
- if (!mapt) {
+ (*pp_rmap)=SMB_REALLOC_ARRAY((*pp_rmap), GROUP_MAP, entries+1);
+ if (!(*pp_rmap)) {
DEBUG(0,("ldapsam_enum_group_mapping: Unable to "
"enlarge group map!\n"));
- SAFE_FREE(*pp_rmap);
return NT_STATUS_UNSUCCESSFUL;
}
- else
- (*pp_rmap) = mapt;
- mapt[entries] = map;
+ (*pp_rmap)[entries] = map;
entries += 1;