diff options
author | Günther Deschner <gd@samba.org> | 2011-04-06 14:21:30 +0200 |
---|---|---|
committer | Günther Deschner <gd@samba.org> | 2011-04-12 12:20:43 +0200 |
commit | 0eece6202c94fdd180f266049e1a3712b9477dc6 (patch) | |
tree | b5924e868ea49fbbea8452ec657574f25dade210 /source3/lib/netapi/cm.c | |
parent | f10274806196cbea8d27cc2b1f1fe5087a2ede2b (diff) | |
download | samba-0eece6202c94fdd180f266049e1a3712b9477dc6.tar.gz samba-0eece6202c94fdd180f266049e1a3712b9477dc6.tar.xz samba-0eece6202c94fdd180f266049e1a3712b9477dc6.zip |
s3-netapi: add libnetapi_get_binding_handle().
Guenther
Diffstat (limited to 'source3/lib/netapi/cm.c')
-rw-r--r-- | source3/lib/netapi/cm.c | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/source3/lib/netapi/cm.c b/source3/lib/netapi/cm.c index 0b8220675da..290194ba2d9 100644 --- a/source3/lib/netapi/cm.c +++ b/source3/lib/netapi/cm.c @@ -253,3 +253,26 @@ WERROR libnetapi_open_pipe(struct libnetapi_ctx *ctx, return WERR_OK; } + +/******************************************************************** +********************************************************************/ + +WERROR libnetapi_get_binding_handle(struct libnetapi_ctx *ctx, + const char *server_name, + const struct ndr_syntax_id *interface, + struct dcerpc_binding_handle **binding_handle) +{ + struct rpc_pipe_client *pipe_cli; + WERROR result; + + *binding_handle = NULL; + + result = libnetapi_open_pipe(ctx, server_name, interface, &pipe_cli); + if (!W_ERROR_IS_OK(result)) { + return result; + } + + *binding_handle = pipe_cli->binding_handle; + + return WERR_OK; +} |