diff options
author | Michael Adam <obnox@samba.org> | 2012-02-26 01:45:00 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2012-02-28 00:08:54 +0100 |
commit | 28b77605c48494b27e50d18c488c7a65be74fce3 (patch) | |
tree | 2c948750a94b87defe483fe33cc4c56e78b6ef49 /source4/libcli | |
parent | e9210987c6961a9fd81602d155604eb4dbe388fa (diff) | |
download | samba-28b77605c48494b27e50d18c488c7a65be74fce3.tar.gz samba-28b77605c48494b27e50d18c488c7a65be74fce3.tar.bz2 samba-28b77605c48494b27e50d18c488c7a65be74fce3.zip |
s4:libcli:smb2: add a smb2_connect_ext variant of smb2_connect that takes a previous_session argument
Diffstat (limited to 'source4/libcli')
-rw-r--r-- | source4/libcli/smb2/connect.c | 48 |
1 files changed, 36 insertions, 12 deletions
diff --git a/source4/libcli/smb2/connect.c b/source4/libcli/smb2/connect.c index d9d430ddd5..c743b90ce5 100644 --- a/source4/libcli/smb2/connect.c +++ b/source4/libcli/smb2/connect.c @@ -269,17 +269,18 @@ NTSTATUS smb2_connect_recv(struct tevent_req *req, /* sync version of smb2_connect */ -NTSTATUS smb2_connect(TALLOC_CTX *mem_ctx, - const char *host, - const char **ports, - const char *share, - struct resolve_context *resolve_ctx, - struct cli_credentials *credentials, - struct smb2_tree **tree, - struct tevent_context *ev, - struct smbcli_options *options, - const char *socket_options, - struct gensec_settings *gensec_settings) +NTSTATUS smb2_connect_ext(TALLOC_CTX *mem_ctx, + const char *host, + const char **ports, + const char *share, + struct resolve_context *resolve_ctx, + struct cli_credentials *credentials, + uint64_t previous_session_id, + struct smb2_tree **tree, + struct tevent_context *ev, + struct smbcli_options *options, + const char *socket_options, + struct gensec_settings *gensec_settings) { struct tevent_req *subreq; NTSTATUS status; @@ -297,7 +298,7 @@ NTSTATUS smb2_connect(TALLOC_CTX *mem_ctx, share, resolve_ctx, credentials, - 0, /* previous_session_id */ + previous_session_id, options, socket_options, gensec_settings); @@ -323,3 +324,26 @@ NTSTATUS smb2_connect(TALLOC_CTX *mem_ctx, TALLOC_FREE(frame); return NT_STATUS_OK; } + +NTSTATUS smb2_connect(TALLOC_CTX *mem_ctx, + const char *host, + const char **ports, + const char *share, + struct resolve_context *resolve_ctx, + struct cli_credentials *credentials, + struct smb2_tree **tree, + struct tevent_context *ev, + struct smbcli_options *options, + const char *socket_options, + struct gensec_settings *gensec_settings) +{ + NTSTATUS status; + + status = smb2_connect_ext(mem_ctx, host, ports, share, resolve_ctx, + credentials, + 0, /* previous_session_id */ + tree, ev, options, socket_options, + gensec_settings); + + return status; +} |