diff options
author | Stefan Metzmacher <metze@samba.org> | 2011-11-30 08:33:29 +0100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2011-11-30 13:41:08 +0100 |
commit | b21f344079920194f94bbee7f44d8a6582e4d1a2 (patch) | |
tree | a42c37d4ffa484e13d66953dcfcadaf710b2b94d /source4/libcli | |
parent | 4877be53df1181f75d603fa4edc67c34e1ba5141 (diff) | |
download | samba-b21f344079920194f94bbee7f44d8a6582e4d1a2.tar.gz samba-b21f344079920194f94bbee7f44d8a6582e4d1a2.tar.bz2 samba-b21f344079920194f94bbee7f44d8a6582e4d1a2.zip |
s4:libcli: use smbcli_sock_connect() in smbcli_socket_connect()
metze
Diffstat (limited to 'source4/libcli')
-rw-r--r-- | source4/libcli/cliconnect.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/source4/libcli/cliconnect.c b/source4/libcli/cliconnect.c index cdb04fb1f6..4047d36369 100644 --- a/source4/libcli/cliconnect.c +++ b/source4/libcli/cliconnect.c @@ -43,11 +43,17 @@ bool smbcli_socket_connect(struct smbcli_state *cli, const char *server, uint32_t timeout_msec = options->request_timeout * 1000; NTSTATUS status; - sock = smbcli_sock_connect_byname(server, ports, NULL, - resolve_ctx, ev_ctx, - socket_options); - - if (sock == NULL) return false; + status = smbcli_sock_connect(cli, + NULL, /* host_addr */ + ports, + server, + resolve_ctx, + ev_ctx, + socket_options, + &sock); + if (!NT_STATUS_IS_OK(status)) { + return false; + } status = smbcli_transport_connect(sock, timeout_msec, |