summaryrefslogtreecommitdiff
path: root/source4/client
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-11-02 16:07:28 +0100
committerJelmer Vernooij <jelmer@samba.org>2008-11-02 16:07:28 +0100
commitff36c52d8c7f146eca9c6c678456708a8e2efbab (patch)
tree8ae184942009eaef07148baf6ef7f33064555b40 /source4/client
parent7a0e5de08d487108c604b4bab8a2c8e689808d9f (diff)
downloadsamba-ff36c52d8c7f146eca9c6c678456708a8e2efbab.tar.gz
samba-ff36c52d8c7f146eca9c6c678456708a8e2efbab.tar.bz2
samba-ff36c52d8c7f146eca9c6c678456708a8e2efbab.zip
Remove another use of global_loadparm.
Eventually, we should move some of these parameters into a separate struct (perhaps into smb_transport_options?), to avoid the long lists of parameters.
Diffstat (limited to 'source4/client')
-rw-r--r--source4/client/cifsdd.h3
-rw-r--r--source4/client/cifsddio.c18
-rw-r--r--source4/client/client.c9
3 files changed, 20 insertions, 10 deletions
diff --git a/source4/client/cifsdd.h b/source4/client/cifsdd.h
index cfc37cad54..28fe6778f4 100644
--- a/source4/client/cifsdd.h
+++ b/source4/client/cifsdd.h
@@ -100,7 +100,8 @@ struct dd_iohandle * dd_open_path(struct resolve_context *resolve_ctx,
const char *socket_options,
struct smbcli_options *smb_options,
struct smbcli_session_options *smb_session_options,
- struct smb_iconv_convenience *iconv_convenience);
+ struct smb_iconv_convenience *iconv_convenience,
+ struct gensec_settings *gensec_settings);
bool dd_fill_block(struct dd_iohandle * h, uint8_t * buf,
uint64_t * buf_size, uint64_t need_size, uint64_t block_size);
bool dd_flush_block(struct dd_iohandle * h, uint8_t * buf,
diff --git a/source4/client/cifsddio.c b/source4/client/cifsddio.c
index 49c32a37dc..06631ee3ac 100644
--- a/source4/client/cifsddio.c
+++ b/source4/client/cifsddio.c
@@ -228,7 +228,8 @@ static struct smbcli_state * init_smb_session(struct resolve_context *resolve_ct
const char *socket_options,
struct smbcli_options *options,
struct smbcli_session_options *session_options,
- struct smb_iconv_convenience *iconv_convenience)
+ struct smb_iconv_convenience *iconv_convenience,
+ struct gensec_settings *gensec_settings)
{
NTSTATUS ret;
struct smbcli_state * cli = NULL;
@@ -242,7 +243,8 @@ static struct smbcli_state * init_smb_session(struct resolve_context *resolve_ct
cmdline_credentials, resolve_ctx,
ev, options,
session_options,
- iconv_convenience);
+ iconv_convenience,
+ gensec_settings);
if (!NT_STATUS_IS_OK(ret)) {
fprintf(stderr, "%s: connecting to //%s/%s: %s\n",
@@ -311,7 +313,8 @@ static struct dd_iohandle * open_cifs_handle(struct resolve_context *resolve_ctx
const char *socket_options,
struct smbcli_options *smb_options,
struct smbcli_session_options *smb_session_options,
- struct smb_iconv_convenience *iconv_convenience)
+ struct smb_iconv_convenience *iconv_convenience,
+ struct gensec_settings *gensec_settings)
{
struct cifs_handle * smbh;
@@ -334,7 +337,8 @@ static struct dd_iohandle * open_cifs_handle(struct resolve_context *resolve_ctx
if ((smbh->cli = init_smb_session(resolve_ctx, ev, host, ports, share,
socket_options,
smb_options, smb_session_options,
- iconv_convenience)) == NULL) {
+ iconv_convenience,
+ gensec_settings)) == NULL) {
return(NULL);
}
@@ -358,7 +362,8 @@ struct dd_iohandle * dd_open_path(struct resolve_context *resolve_ctx,
const char *socket_options,
struct smbcli_options *smb_options,
struct smbcli_session_options *smb_session_options,
- struct smb_iconv_convenience *iconv_convenience)
+ struct smb_iconv_convenience *iconv_convenience,
+ struct gensec_settings *gensec_settings)
{
if (file_exist(path)) {
return(open_fd_handle(path, io_size, options));
@@ -378,7 +383,8 @@ struct dd_iohandle * dd_open_path(struct resolve_context *resolve_ctx,
io_size, options,
socket_options, smb_options,
smb_session_options,
- iconv_convenience));
+ iconv_convenience,
+ gensec_settings));
}
return(open_fd_handle(path, io_size, options));
diff --git a/source4/client/client.c b/source4/client/client.c
index 5066df1f54..a600b5fb0c 100644
--- a/source4/client/client.c
+++ b/source4/client/client.c
@@ -3049,7 +3049,8 @@ static bool do_connect(struct smbclient_context *ctx,
struct cli_credentials *cred,
struct smbcli_options *options,
struct smbcli_session_options *session_options,
- struct smb_iconv_convenience *iconv_convenience)
+ struct smb_iconv_convenience *iconv_convenience,
+ struct gensec_settings *gensec_settings)
{
NTSTATUS status;
char *server, *share;
@@ -3071,7 +3072,8 @@ static bool do_connect(struct smbclient_context *ctx,
socket_options,
cred, resolve_ctx,
ev_ctx, options, session_options,
- iconv_convenience);
+ iconv_convenience,
+ gensec_settings);
if (!NT_STATUS_IS_OK(status)) {
d_printf("Connection to \\\\%s\\%s failed - %s\n",
server, share, nt_errstr(status));
@@ -3284,7 +3286,8 @@ static int do_message_op(const char *netbios_name, const char *desthost,
desthost, lp_smb_ports(cmdline_lp_ctx), service,
lp_socket_options(cmdline_lp_ctx),
cmdline_credentials, &smb_options, &smb_session_options,
- lp_iconv_convenience(cmdline_lp_ctx)))
+ lp_iconv_convenience(cmdline_lp_ctx),
+ lp_gensec_settings(ctx, cmdline_lp_ctx)))
return 1;
if (base_directory)