diff options
author | Rafal Szczesniak <mimir@samba.org> | 2006-05-04 14:52:03 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 14:05:36 -0500 |
commit | 538adbf677d225da8abc2adaefafa2a7c305ec17 (patch) | |
tree | 9d686406550bc40e4fda47459ef3634b1d350422 /source4/libnet/libnet_join.c | |
parent | 209edfb807cbe58f929b644989b5374a5aafb85f (diff) | |
download | samba-538adbf677d225da8abc2adaefafa2a7c305ec17.tar.gz samba-538adbf677d225da8abc2adaefafa2a7c305ec17.tar.xz samba-538adbf677d225da8abc2adaefafa2a7c305ec17.zip |
r15435: Turn libnet_RpcConnectDCInfo into another level of libnet_RpcConnect
and make it async. Also, update any other usages of old function.
Build goes fine and so do tests, comments to follow.
rafal
(This used to be commit aef0a2de9d2f01a6f619e3fccc8715288f5c37a3)
Diffstat (limited to 'source4/libnet/libnet_join.c')
-rw-r--r-- | source4/libnet/libnet_join.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/source4/libnet/libnet_join.c b/source4/libnet/libnet_join.c index 743076ee72..fb28eaed2f 100644 --- a/source4/libnet/libnet_join.c +++ b/source4/libnet/libnet_join.c @@ -404,7 +404,7 @@ NTSTATUS libnet_JoinDomain(struct libnet_context *ctx, TALLOC_CTX *mem_ctx, stru NTSTATUS status, cu_status; - struct libnet_RpcConnectDCInfo *connect_with_info; + struct libnet_RpcConnect *connect_with_info; struct dcerpc_pipe *samr_pipe; struct samr_Connect sc; @@ -445,7 +445,7 @@ NTSTATUS libnet_JoinDomain(struct libnet_context *ctx, TALLOC_CTX *mem_ctx, stru return NT_STATUS_NO_MEMORY; } - connect_with_info = talloc(tmp_ctx, struct libnet_RpcConnectDCInfo); + connect_with_info = talloc(tmp_ctx, struct libnet_RpcConnect); if (!connect_with_info) { r->out.error_string = NULL; talloc_free(tmp_ctx); @@ -454,19 +454,18 @@ NTSTATUS libnet_JoinDomain(struct libnet_context *ctx, TALLOC_CTX *mem_ctx, stru /* prepare connect to the LSA pipe of PDC */ if (r->in.level == LIBNET_JOINDOMAIN_AUTOMATIC) { - connect_with_info->level = LIBNET_RPC_CONNECT_PDC; connect_with_info->in.name = r->in.domain_name; } else { - connect_with_info->level = LIBNET_RPC_CONNECT_BINDING; connect_with_info->in.binding = r->in.binding; } + connect_with_info->level = LIBNET_RPC_CONNECT_DC_INFO; connect_with_info->in.dcerpc_iface = &dcerpc_table_samr; + /* establish a SAMR connection, on the same CIFS transport */ - - status = libnet_RpcConnectDCInfo(ctx, connect_with_info); + status = libnet_RpcConnect(ctx, tmp_ctx, connect_with_info); if (!NT_STATUS_IS_OK(status)) { if (r->in.binding) { r->out.error_string = talloc_asprintf(mem_ctx, |