From a9e03337c1dbf13dcab5bf1f825bc1853b61256e Mon Sep 17 00:00:00 2001 From: Jeremy Allison Date: Thu, 26 Jan 2012 17:10:44 -0800 Subject: Finally remove all malloc()'s from the substitute code. Now totally talloc() based. Autobuild-User: Jeremy Allison Autobuild-Date: Fri Jan 27 03:43:21 CET 2012 on sn-devel-104 --- source3/passdb/pdb_ldap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source3/passdb') diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c index 49eb3e12fa..7c1681031a 100644 --- a/source3/passdb/pdb_ldap.c +++ b/source3/passdb/pdb_ldap.c @@ -2075,13 +2075,13 @@ static NTSTATUS ldapsam_rename_sam_account(struct pdb_methods *my_methods, oldname = pdb_get_username(old_acct); /* rename the posix user */ - rename_script = SMB_STRDUP(lp_renameuser_script()); + rename_script = talloc_strdup(talloc_tos(), lp_renameuser_script()); if (rename_script == NULL) { return NT_STATUS_NO_MEMORY; } if (!(*rename_script)) { - SAFE_FREE(rename_script); + TALLOC_FREE(rename_script); return NT_STATUS_ACCESS_DENIED; } @@ -2114,7 +2114,7 @@ static NTSTATUS ldapsam_rename_sam_account(struct pdb_methods *my_methods, DEBUG(rc ? 0 : 3,("Running the command `%s' gave %d\n", rename_script, rc)); - SAFE_FREE(rename_script); + TALLOC_FREE(rename_script); if (rc == 0) { smb_nscd_flush_user_cache(); -- cgit