Fix crash bug in pdb_init_ldapsam().
authorGünther Deschner <gd@samba.org>
Tue, 4 Mar 2008 10:02:26 +0000 (11:02 +0100)
committerKarolin Seeger <kseeger@samba.org>
Tue, 4 Mar 2008 10:22:04 +0000 (11:22 +0100)
Karolin, this needs to be in 3-2-stable.

Guenther
(cherry picked from commit 0d73bde6de4391e7aec862424762473441fa0905)
(This used to be commit 4c2d6ce18daf07de7233e3e90bd24fa2a5f9e945)

source3/passdb/pdb_ldap.c

index ce79dce668b44bd25d60517b56f47ca41f5e109a..87a648a5b4b54b5bb35caa05616f2de1db5760fb 100644 (file)
@@ -6264,7 +6264,7 @@ NTSTATUS pdb_init_ldapsam(struct pdb_methods **pdb_method, const char *location)
                    entry,
                    get_userattr_key2string(ldap_state->schema_ver,
                                            LDAP_ATTR_USER_SID),
-                   NULL);
+                   talloc_tos());
 
        if (domain_sid_string) {
                bool found_sid;
@@ -6300,7 +6300,7 @@ NTSTATUS pdb_init_ldapsam(struct pdb_methods **pdb_method, const char *location)
                    entry,
                    get_attr_key2string( dominfo_attr_list,
                                         LDAP_ATTR_ALGORITHMIC_RID_BASE ),
-                   NULL);
+                   talloc_tos());
        if (alg_rid_base_string) {
                alg_rid_base = (uint32)atol(alg_rid_base_string);
                if (alg_rid_base != algorithmic_rid_base()) {