diff options
author | Matthias Dieter Wallnöfer <mwallnoefer@yahoo.de> | 2009-11-22 15:51:18 +0100 |
---|---|---|
committer | Matthias Dieter Wallnöfer <mwallnoefer@yahoo.de> | 2009-11-22 15:51:18 +0100 |
commit | 8b345ef19e18ccfebf102750316976f512fda6ad (patch) | |
tree | aefb5d3b324f6ca5d9431a3ab1d4bb3164a08865 /source4/rpc_server/netlogon | |
parent | 1fb28b0204038e5cef63c2f1fbdc2b5424570e44 (diff) | |
download | samba-8b345ef19e18ccfebf102750316976f512fda6ad.tar.gz samba-8b345ef19e18ccfebf102750316976f512fda6ad.tar.bz2 samba-8b345ef19e18ccfebf102750316976f512fda6ad.zip |
s4:netlogon RPC - Fix up the error handling
Diffstat (limited to 'source4/rpc_server/netlogon')
-rw-r--r-- | source4/rpc_server/netlogon/dcerpc_netlogon.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/source4/rpc_server/netlogon/dcerpc_netlogon.c b/source4/rpc_server/netlogon/dcerpc_netlogon.c index 1cdb172225..8a833b0d12 100644 --- a/source4/rpc_server/netlogon/dcerpc_netlogon.c +++ b/source4/rpc_server/netlogon/dcerpc_netlogon.c @@ -1416,7 +1416,7 @@ static WERROR dcesrv_netr_DsRGetDCNameEx2(struct dcesrv_call_state *dce_call, TA /* Windows 7 sends the domain name in the form the user typed, so we * have to cope with both the short and long form here */ if (r->in.domain_name != NULL && - !lp_is_my_domain_or_realm(dce_call->conn->dce_ctx->lp_ctx, + !lp_is_my_domain_or_realm(dce_call->conn->dce_ctx->lp_ctx, r->in.domain_name)) { return WERR_NO_SUCH_DOMAIN; } @@ -1429,6 +1429,7 @@ static WERROR dcesrv_netr_DsRGetDCNameEx2(struct dcesrv_call_state *dce_call, TA ret = gendb_search_dn(sam_ctx, mem_ctx, domain_dn, &res, attrs); if (ret != 1) { + return WERR_GENERAL_FAILURE; } info = talloc(mem_ctx, struct netr_DsRGetDCNameInfo); @@ -1603,9 +1604,6 @@ static WERROR dcesrv_netr_DsrEnumerateDomainTrusts(struct dcesrv_call_state *dce ret = gendb_search_dn(sam_ctx, mem_ctx, NULL, &dom_res, dom_attrs); - if (ret == -1) { - return WERR_GENERAL_FAILURE; - } if (ret != 1) { return WERR_GENERAL_FAILURE; } |