summaryrefslogtreecommitdiff
path: root/source4/libcli/cliconnect.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/libcli/cliconnect.c')
-rw-r--r--source4/libcli/cliconnect.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/source4/libcli/cliconnect.c b/source4/libcli/cliconnect.c
index d670324c88..e25a400985 100644
--- a/source4/libcli/cliconnect.c
+++ b/source4/libcli/cliconnect.c
@@ -58,7 +58,17 @@ bool smbcli_transport_establish(struct smbcli_state *cli,
struct nbt_name *calling,
struct nbt_name *called)
{
- return smbcli_transport_connect(cli->transport, calling, called);
+ uint32_t timeout_msec = cli->transport->options.request_timeout * 1000;
+ NTSTATUS status;
+
+ status = smbcli_transport_connect(cli->transport->socket,
+ timeout_msec,
+ calling, called);
+ if (!NT_STATUS_IS_OK(status)) {
+ return false;
+ }
+
+ return true;
}
/* wrapper around smb_raw_negotiate() */