summaryrefslogtreecommitdiff
path: root/source3/nsswitch
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/nsswitch
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/nsswitch')
-rw-r--r--source3/nsswitch/winbindd_cm.c7
-rw-r--r--source3/nsswitch/winbindd_misc.c7
2 files changed, 8 insertions, 6 deletions
diff --git a/source3/nsswitch/winbindd_cm.c b/source3/nsswitch/winbindd_cm.c
index 17663a7cfc..8f82f97d88 100644
--- a/source3/nsswitch/winbindd_cm.c
+++ b/source3/nsswitch/winbindd_cm.c
@@ -289,6 +289,7 @@ static BOOL get_dc_name_via_netlogon(const struct winbindd_domain *domain,
struct winbindd_domain *our_domain = NULL;
struct rpc_pipe_client *netlogon_pipe = NULL;
NTSTATUS result;
+ WERROR werr;
TALLOC_CTX *mem_ctx;
fstring tmp;
@@ -316,14 +317,14 @@ static BOOL get_dc_name_via_netlogon(const struct winbindd_domain *domain,
return False;
}
- result = rpccli_netlogon_getdcname(netlogon_pipe, mem_ctx, our_domain->dcname,
+ werr = rpccli_netlogon_getdcname(netlogon_pipe, mem_ctx, our_domain->dcname,
domain->name, tmp);
talloc_destroy(mem_ctx);
- if (!NT_STATUS_IS_OK(result)) {
+ if (!W_ERROR_IS_OK(werr)) {
DEBUG(10, ("rpccli_netlogon_getdcname failed: %s\n",
- nt_errstr(result)));
+ dos_errstr(werr)));
return False;
}
diff --git a/source3/nsswitch/winbindd_misc.c b/source3/nsswitch/winbindd_misc.c
index 9fb05d9df6..34ce468516 100644
--- a/source3/nsswitch/winbindd_misc.c
+++ b/source3/nsswitch/winbindd_misc.c
@@ -195,6 +195,7 @@ enum winbindd_result winbindd_dual_getdcname(struct winbindd_domain *domain,
char *p;
struct rpc_pipe_client *netlogon_pipe;
NTSTATUS result;
+ WERROR werr;
state->request.domain_name
[sizeof(state->request.domain_name)-1] = '\0';
@@ -209,12 +210,12 @@ enum winbindd_result winbindd_dual_getdcname(struct winbindd_domain *domain,
return WINBINDD_ERROR;
}
- result = rpccli_netlogon_getdcname(netlogon_pipe, state->mem_ctx, domain->dcname,
+ werr = rpccli_netlogon_getdcname(netlogon_pipe, state->mem_ctx, domain->dcname,
state->request.domain_name,
dcname_slash);
- if (!NT_STATUS_IS_OK(result)) {
- DEBUG(5, ("Error requesting DCname: %s\n", nt_errstr(result)));
+ if (!W_ERROR_IS_OK(werr)) {
+ DEBUG(5, ("Error requesting DCname: %s\n", dos_errstr(werr)));
return WINBINDD_ERROR;
}