summaryrefslogtreecommitdiff
path: root/source3/rpcclient/cmd_netlogon.c
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2006-10-06 16:13:10 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:15:16 -0500
commitadc299bd0863a42f699874f1933dbace3abea316 (patch)
tree207c6e0a62956cc142570e8bdfa3849b4f4c4c2d /source3/rpcclient/cmd_netlogon.c
parenta6e45f0da5b7a187f652fb80d172007d36a5e855 (diff)
downloadsamba-adc299bd0863a42f699874f1933dbace3abea316.tar.gz
samba-adc299bd0863a42f699874f1933dbace3abea316.tar.bz2
samba-adc299bd0863a42f699874f1933dbace3abea316.zip
r19143: getdcname on the NETLOGON pipe returns WERROR, not NTSTATUS.
Guenther (This used to be commit 44e228ac796fca2db8509915067511ed705032bf)
Diffstat (limited to 'source3/rpcclient/cmd_netlogon.c')
-rw-r--r--source3/rpcclient/cmd_netlogon.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/source3/rpcclient/cmd_netlogon.c b/source3/rpcclient/cmd_netlogon.c
index ee0fc2e14c..1a145711cc 100644
--- a/source3/rpcclient/cmd_netlogon.c
+++ b/source3/rpcclient/cmd_netlogon.c
@@ -45,21 +45,21 @@ static NTSTATUS cmd_netlogon_logon_ctrl2(struct rpc_pipe_client *cli,
return result;
}
-static NTSTATUS cmd_netlogon_getdcname(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx, int argc,
- const char **argv)
+static WERROR cmd_netlogon_getdcname(struct rpc_pipe_client *cli,
+ TALLOC_CTX *mem_ctx, int argc,
+ const char **argv)
{
fstring dcname;
- NTSTATUS result = NT_STATUS_UNSUCCESSFUL;
+ WERROR result = WERR_GENERAL_FAILURE;
if (argc != 2) {
fprintf(stderr, "Usage: %s domainname\n", argv[0]);
- return NT_STATUS_OK;
+ return WERR_OK;
}
result = rpccli_netlogon_getdcname(cli, mem_ctx, cli->cli->desthost, argv[1], dcname);
- if (!NT_STATUS_IS_OK(result))
+ if (!W_ERROR_IS_OK(result))
goto done;
/* Display results */
@@ -368,7 +368,7 @@ struct cmd_set netlogon_commands[] = {
{ "NETLOGON" },
{ "logonctrl2", RPC_RTYPE_NTSTATUS, cmd_netlogon_logon_ctrl2, NULL, PI_NETLOGON, NULL, "Logon Control 2", "" },
- { "getdcname", RPC_RTYPE_NTSTATUS, cmd_netlogon_getdcname, NULL, PI_NETLOGON, NULL, "Get trusted DC name", "" },
+ { "getdcname", RPC_RTYPE_WERROR, NULL, cmd_netlogon_getdcname, PI_NETLOGON, NULL, "Get trusted DC name", "" },
{ "dsr_getdcname", RPC_RTYPE_WERROR, NULL, cmd_netlogon_dsr_getdcname, PI_NETLOGON, NULL, "Get trusted DC name", "" },
{ "dsr_getsitename", RPC_RTYPE_WERROR, NULL, cmd_netlogon_dsr_getsitename, PI_NETLOGON, NULL, "Get sitename", "" },
{ "logonctrl", RPC_RTYPE_NTSTATUS, cmd_netlogon_logon_ctrl, NULL, PI_NETLOGON, NULL, "Logon Control", "" },