summaryrefslogtreecommitdiff
path: root/source3/librpc/rpc/dcerpc_ep.c
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2011-02-22 11:53:35 +0100
committerGünther Deschner <gd@samba.org>2011-03-08 11:41:28 +0100
commita45353b3e2e0a8dd5f9055c50e0d38bce7dda22c (patch)
treee5845a142938b00a08baff70f2ab8d12d4bdd0c0 /source3/librpc/rpc/dcerpc_ep.c
parent98443b8b3dbbf6bd5a7738560d1dfc44622db820 (diff)
downloadsamba-a45353b3e2e0a8dd5f9055c50e0d38bce7dda22c.tar.gz
samba-a45353b3e2e0a8dd5f9055c50e0d38bce7dda22c.tar.bz2
samba-a45353b3e2e0a8dd5f9055c50e0d38bce7dda22c.zip
s3-librpc: Added tcpip support for dcerpc_binding_vector_create.
Signed-off-by: Günther Deschner <gd@samba.org>
Diffstat (limited to 'source3/librpc/rpc/dcerpc_ep.c')
-rw-r--r--source3/librpc/rpc/dcerpc_ep.c13
1 files changed, 12 insertions, 1 deletions
diff --git a/source3/librpc/rpc/dcerpc_ep.c b/source3/librpc/rpc/dcerpc_ep.c
index 54db4cdbca..bda24a6865 100644
--- a/source3/librpc/rpc/dcerpc_ep.c
+++ b/source3/librpc/rpc/dcerpc_ep.c
@@ -27,6 +27,7 @@
NTSTATUS dcerpc_binding_vector_create(TALLOC_CTX *mem_ctx,
const struct ndr_interface_table *iface,
+ uint16_t port,
struct dcerpc_binding_vector **pbvec)
{
struct dcerpc_binding_vector *bvec;
@@ -81,7 +82,17 @@ NTSTATUS dcerpc_binding_vector_create(TALLOC_CTX *mem_ctx,
}
break;
case NCACN_IP_TCP:
- /* TODO */
+ if (port == 0) {
+ continue;
+ }
+
+ b->endpoint = talloc_asprintf(b, "%u", port);
+ if (b->endpoint == NULL) {
+ status = NT_STATUS_NO_MEMORY;
+ goto done;
+ }
+
+ break;
case NCALRPC:
/* TODO */
default: