s3-lsa: Fix _lsa_LookupNames2() server implementation which always returned a NULL...
authorGünther Deschner <gd@samba.org>
Mon, 11 May 2009 16:27:40 +0000 (18:27 +0200)
committerKarolin Seeger <kseeger@samba.org>
Mon, 10 Aug 2009 15:59:02 +0000 (17:59 +0200)
Found by torture test.

This makes it possible to search for users while adding them to groups via
windows usermanager.

Fixes bug #6484.

Guenther
(cherry picked from commit 0cfe59f1b580371f445b50151ceae5aef02bf0c4)
(cherry picked from commit b653d1b1186e1c43f1ad0a64d19ee2fc015594a6)

source/rpc_server/srv_lsa_nt.c

index 697cc5208db9624f9fa0167355bc1f411d667c04..cf883bbddfac65bf47d3a2dfa9ecf566c80625e7 100644 (file)
@@ -1092,6 +1092,7 @@ NTSTATUS _lsa_LookupNames2(pipes_struct *p,
 
        status = _lsa_LookupNames(p, &q);
 
+       sid_array2->count = sid_array->count;
        sid_array2->sids = TALLOC_ARRAY(p->mem_ctx, struct lsa_TranslatedSid2, sid_array->count);
        if (!sid_array2->sids) {
                return NT_STATUS_NO_MEMORY;