summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2011-01-18 11:36:48 +0100
committerGünther Deschner <gd@samba.org>2011-02-01 23:29:13 +0100
commita87a9fc9ce68438526d5146feab04986c719f11b (patch)
tree59d902684b5794d760839b16f756b2f0b3d5b18d
parent021e0b4cdaf430e55e84a8b26fe1eb3d1edd88b7 (diff)
downloadsamba-a87a9fc9ce68438526d5146feab04986c719f11b.tar.gz
samba-a87a9fc9ce68438526d5146feab04986c719f11b.tar.bz2
samba-a87a9fc9ce68438526d5146feab04986c719f11b.zip
s3-net: prefer dcerpc_samr_X functions in rpc_sh_user_show_internals.
Guenther
-rw-r--r--source3/utils/net_rpc.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/source3/utils/net_rpc.c b/source3/utils/net_rpc.c
index 8ecc1af557..77eb4e7220 100644
--- a/source3/utils/net_rpc.c
+++ b/source3/utils/net_rpc.c
@@ -1231,8 +1231,9 @@ static NTSTATUS rpc_sh_user_show_internals(struct net_context *c,
struct policy_handle *user_hnd,
int argc, const char **argv)
{
- NTSTATUS result;
+ NTSTATUS status, result;
union samr_UserInfo *info = NULL;
+ struct dcerpc_binding_handle *b = pipe_hnd->binding_handle;
if (argc != 0) {
d_fprintf(stderr, "%s %s show <username>\n", _("Usage:"),
@@ -1240,10 +1241,14 @@ static NTSTATUS rpc_sh_user_show_internals(struct net_context *c,
return NT_STATUS_INVALID_PARAMETER;
}
- result = rpccli_samr_QueryUserInfo(pipe_hnd, mem_ctx,
+ status = dcerpc_samr_QueryUserInfo(b, mem_ctx,
user_hnd,
21,
- &info);
+ &info,
+ &result);
+ if (!NT_STATUS_IS_OK(status)) {
+ return status;
+ }
if (!NT_STATUS_IS_OK(result)) {
return result;
}