From f4e485117a0dea627addfb8518e6517c7104fd9e Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Mon, 24 Nov 2003 13:19:00 +0000 Subject: * fixed byte order in epmapper parsing * allow rpc transport to be specified on command line in smbtorture (This used to be commit 8a82050fd6f45bcdb31c2c365eaed5fc12599e4f) --- source4/librpc/rpc/dcerpc_tcp.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'source4/librpc') diff --git a/source4/librpc/rpc/dcerpc_tcp.c b/source4/librpc/rpc/dcerpc_tcp.c index 785ef46423..ec94baf583 100644 --- a/source4/librpc/rpc/dcerpc_tcp.c +++ b/source4/librpc/rpc/dcerpc_tcp.c @@ -155,6 +155,10 @@ NTSTATUS dcerpc_pipe_open_tcp(struct dcerpc_pipe **p, int fd; struct in_addr addr; + if (port == 0) { + port = 135; + } + addr.s_addr = interpret_addr(server); if (addr.s_addr == 0) { return NT_STATUS_BAD_NETWORK_NAME; @@ -195,6 +199,7 @@ NTSTATUS dcerpc_pipe_open_tcp(struct dcerpc_pipe **p, if (!NT_STATUS_IS_OK(status)) { dcerpc_pipe_close(*p); + return status; } return NT_STATUS_OK; -- cgit