summaryrefslogtreecommitdiff
path: root/source4/libcli/raw/clisocket.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/libcli/raw/clisocket.c')
-rw-r--r--source4/libcli/raw/clisocket.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source4/libcli/raw/clisocket.c b/source4/libcli/raw/clisocket.c
index 851cf67caa..ad1c6a13b8 100644
--- a/source4/libcli/raw/clisocket.c
+++ b/source4/libcli/raw/clisocket.c
@@ -1,5 +1,6 @@
/*
Unix SMB/CIFS implementation.
+
SMB client socket context management functions
Copyright (C) Andrew Tridgell 1994-2005
@@ -72,6 +73,7 @@ static void smbcli_sock_connect_handler(struct event_context *ev, struct fd_even
c->status = socket_connect_complete(conn->sock->sock, 0);
if (NT_STATUS_IS_OK(c->status)) {
socket_set_option(conn->sock->sock, lp_socket_options(), NULL);
+ conn->sock->hostname = talloc_strdup(conn->sock, conn->dest_host);
c->state = SMBCLI_REQUEST_DONE;
if (c->async.fn) {
c->async.fn(c);