diff options
author | Andrew Bartlett <abartlet@samba.org> | 2011-06-24 16:26:23 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2011-06-24 16:26:23 +1000 |
commit | 6da26870e0ae5acd6ff49a30ec2f6886b44d095e (patch) | |
tree | 850c71039563c16a5d563c47e7ba2ab645baf198 /source3/winbindd/winbindd_rpc.c | |
parent | 6925a799d04c6fa59dd2ddef1f5510f9bb7d17d1 (diff) | |
parent | 2610c05b5b95cc7036b3d6dfb894c6cfbdb68483 (diff) | |
download | samba-6da26870e0ae5acd6ff49a30ec2f6886b44d095e.tar.gz samba-6da26870e0ae5acd6ff49a30ec2f6886b44d095e.tar.bz2 samba-6da26870e0ae5acd6ff49a30ec2f6886b44d095e.zip |
Merge 2610c05b5b95cc7036b3d6dfb894c6cfbdb68483 as Samba-4.0alpha16
Diffstat (limited to 'source3/winbindd/winbindd_rpc.c')
-rw-r--r-- | source3/winbindd/winbindd_rpc.c | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/source3/winbindd/winbindd_rpc.c b/source3/winbindd/winbindd_rpc.c index 82599e7878..e911487324 100644 --- a/source3/winbindd/winbindd_rpc.c +++ b/source3/winbindd/winbindd_rpc.c @@ -26,12 +26,9 @@ #include "includes.h" #include "winbindd.h" #include "winbindd_rpc.h" - #include "rpc_client/rpc_client.h" #include "librpc/gen_ndr/ndr_samr_c.h" -#include "librpc/gen_ndr/srv_samr.h" #include "librpc/gen_ndr/ndr_lsa_c.h" -#include "librpc/gen_ndr/srv_lsa.h" #include "rpc_client/cli_samr.h" #include "rpc_client/cli_lsarpc.h" #include "../libcli/security/security.h" @@ -92,7 +89,7 @@ NTSTATUS rpc_query_user_list(TALLOC_CTX *mem_ctx, num_info += num_dom_users; - info = TALLOC_REALLOC_ARRAY(mem_ctx, + info = talloc_realloc(mem_ctx, info, struct wbint_userinfo, num_info); @@ -184,7 +181,7 @@ NTSTATUS rpc_enum_dom_groups(TALLOC_CTX *mem_ctx, } } - info = TALLOC_REALLOC_ARRAY(mem_ctx, + info = talloc_realloc(mem_ctx, info, struct wb_acct_info, num_info + count); @@ -244,7 +241,7 @@ NTSTATUS rpc_enum_local_groups(TALLOC_CTX *mem_ctx, } } - info = TALLOC_REALLOC_ARRAY(mem_ctx, + info = talloc_realloc(mem_ctx, info, struct wb_acct_info, num_info + count); @@ -407,7 +404,7 @@ NTSTATUS rpc_rids_to_names(TALLOC_CTX *mem_ctx, NTSTATUS status; if (num_rids > 0) { - sids = TALLOC_ARRAY(mem_ctx, struct dom_sid, num_rids); + sids = talloc_array(mem_ctx, struct dom_sid, num_rids); if (sids == NULL) { return NT_STATUS_NO_MEMORY; } @@ -597,7 +594,7 @@ NTSTATUS rpc_lookup_usergroups(TALLOC_CTX *mem_ctx, return result; } - user_grpsids = TALLOC_ARRAY(mem_ctx, struct dom_sid, num_groups); + user_grpsids = talloc_array(mem_ctx, struct dom_sid, num_groups); if (user_grpsids == NULL) { status = NT_STATUS_NO_MEMORY; return status; @@ -647,7 +644,7 @@ NTSTATUS rpc_lookup_useraliases(TALLOC_CTX *mem_ctx, num_queries, num_query_sids)); if (num_query_sids) { - sid_array.sids = TALLOC_ZERO_ARRAY(mem_ctx, struct lsa_SidPtr, num_query_sids); + sid_array.sids = talloc_zero_array(mem_ctx, struct lsa_SidPtr, num_query_sids); if (sid_array.sids == NULL) { return NT_STATUS_NO_MEMORY; } @@ -842,9 +839,9 @@ NTSTATUS rpc_lookup_groupmem(TALLOC_CTX *mem_ctx, * Step #2: Convert list of rids into list of usernames. */ if (num_names > 0) { - names = TALLOC_ZERO_ARRAY(mem_ctx, char *, num_names); - name_types = TALLOC_ZERO_ARRAY(mem_ctx, uint32_t, num_names); - sid_mem = TALLOC_ZERO_ARRAY(mem_ctx, struct dom_sid, num_names); + names = talloc_zero_array(mem_ctx, char *, num_names); + name_types = talloc_zero_array(mem_ctx, uint32_t, num_names); + sid_mem = talloc_zero_array(mem_ctx, struct dom_sid, num_names); if (names == NULL || name_types == NULL || sid_mem == NULL) { return NT_STATUS_NO_MEMORY; } @@ -1069,7 +1066,7 @@ static NTSTATUS rpc_try_lookup_sids3(TALLOC_CTX *mem_ctx, if (NT_STATUS_IS_ERR(result)) { return result; } - names = TALLOC_ZERO_P(mem_ctx, struct lsa_TransNameArray); + names = talloc_zero(mem_ctx, struct lsa_TransNameArray); if (names == NULL) { return NT_STATUS_NO_MEMORY; } @@ -1114,7 +1111,7 @@ NTSTATUS rpc_lookup_sids(TALLOC_CTX *mem_ctx, return status; } - names = TALLOC_ZERO_P(mem_ctx, struct lsa_TransNameArray); + names = talloc_zero(mem_ctx, struct lsa_TransNameArray); if (names == NULL) { return NT_STATUS_NO_MEMORY; } |