diff options
author | Günther Deschner <gd@samba.org> | 2008-07-18 20:10:37 +0200 |
---|---|---|
committer | Günther Deschner <gd@samba.org> | 2008-07-30 16:34:49 +0200 |
commit | 39c344a27fbe1a66281aa36e49e4049286cea0f0 (patch) | |
tree | c3f0319db42e4d5170db2732e566f58d0d25f9d4 /source3/lib/netapi | |
parent | 1a6aecaea81a06602e2d216a766ab9f7c21f6a77 (diff) | |
download | samba-39c344a27fbe1a66281aa36e49e4049286cea0f0.tar.gz samba-39c344a27fbe1a66281aa36e49e4049286cea0f0.tar.bz2 samba-39c344a27fbe1a66281aa36e49e4049286cea0f0.zip |
netapi: fix NetLocalGroupAdd.
Guenther
(This used to be commit d4594a7a03381fb251c9f8caf4c70e1ed97674b6)
Diffstat (limited to 'source3/lib/netapi')
-rw-r--r-- | source3/lib/netapi/localgroup.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/source3/lib/netapi/localgroup.c b/source3/lib/netapi/localgroup.c index fe36d86b05..57067621b7 100644 --- a/source3/lib/netapi/localgroup.c +++ b/source3/lib/netapi/localgroup.c @@ -209,6 +209,8 @@ WERROR NetLocalGroupAdd_r(struct libnetapi_ctx *ctx, goto done; } + init_lsa_String(&lsa_account_name, alias_name); + status = rpccli_samr_CreateDomAlias(pipe_cli, ctx, &domain_handle, &lsa_account_name, @@ -786,6 +788,13 @@ WERROR NetLocalGroupEnum_r(struct libnetapi_ctx *ctx, return WERR_UNKNOWN_LEVEL; } + if (r->out.total_entries) { + *r->out.total_entries = 0; + } + if (r->out.entries_read) { + *r->out.entries_read = 0; + } + ZERO_STRUCT(connect_handle); ZERO_STRUCT(builtin_handle); ZERO_STRUCT(domain_handle); @@ -836,6 +845,10 @@ WERROR NetLocalGroupEnum_r(struct libnetapi_ctx *ctx, goto done; } + if (r->out.total_entries) { + *r->out.total_entries += builtin_info->info2.num_aliases; + } + status = rpccli_samr_QueryDomainInfo(pipe_cli, ctx, &domain_handle, 2, @@ -845,6 +858,10 @@ WERROR NetLocalGroupEnum_r(struct libnetapi_ctx *ctx, goto done; } + if (r->out.total_entries) { + *r->out.total_entries += domain_info->info2.num_aliases; + } + status = rpccli_samr_EnumDomainAliases(pipe_cli, ctx, &builtin_handle, r->in.resume_handle, |