mirror of
https://github.com/samba-team/samba.git
synced 2025-01-10 01:18:15 +03:00
s4:param: use struct initializer in lpcfg_smbcli_options()
We should zero all fields not initialiazed explicitly. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Günther Deschner <gd@samba.org>
This commit is contained in:
parent
0d2566210a
commit
9f3ab6a113
@ -35,20 +35,22 @@
|
||||
void lpcfg_smbcli_options(struct loadparm_context *lp_ctx,
|
||||
struct smbcli_options *options)
|
||||
{
|
||||
options->max_xmit = lpcfg_max_xmit(lp_ctx);
|
||||
options->max_mux = lpcfg_max_mux(lp_ctx);
|
||||
options->use_spnego = lpcfg_nt_status_support(lp_ctx) && lpcfg_client_use_spnego(lp_ctx);
|
||||
options->signing = lpcfg_client_signing(lp_ctx);
|
||||
options->request_timeout = SMB_REQUEST_TIMEOUT;
|
||||
options->ntstatus_support = lpcfg_nt_status_support(lp_ctx);
|
||||
options->min_protocol = lpcfg_client_min_protocol(lp_ctx);
|
||||
options->max_protocol = lpcfg__client_max_protocol(lp_ctx);
|
||||
options->unicode = lpcfg_unicode(lp_ctx);
|
||||
options->use_oplocks = true;
|
||||
options->use_level2_oplocks = true;
|
||||
options->smb2_capabilities = SMB2_CAP_ALL;
|
||||
options->client_guid = GUID_random();
|
||||
options->max_credits = WINDOWS_CLIENT_PURE_SMB2_NEGPROT_INITIAL_CREDIT_ASK;
|
||||
*options = (struct smbcli_options) {
|
||||
.max_xmit = lpcfg_max_xmit(lp_ctx),
|
||||
.max_mux = lpcfg_max_mux(lp_ctx),
|
||||
.use_spnego = lpcfg_nt_status_support(lp_ctx) && lpcfg_client_use_spnego(lp_ctx),
|
||||
.signing = lpcfg_client_signing(lp_ctx),
|
||||
.request_timeout = SMB_REQUEST_TIMEOUT,
|
||||
.ntstatus_support = lpcfg_nt_status_support(lp_ctx),
|
||||
.min_protocol = lpcfg_client_min_protocol(lp_ctx),
|
||||
.max_protocol = lpcfg__client_max_protocol(lp_ctx),
|
||||
.unicode = lpcfg_unicode(lp_ctx),
|
||||
.use_oplocks = true,
|
||||
.use_level2_oplocks = true,
|
||||
.smb2_capabilities = SMB2_CAP_ALL,
|
||||
.client_guid = GUID_random(),
|
||||
.max_credits = WINDOWS_CLIENT_PURE_SMB2_NEGPROT_INITIAL_CREDIT_ASK,
|
||||
};
|
||||
}
|
||||
|
||||
void lpcfg_smbcli_session_options(struct loadparm_context *lp_ctx,
|
||||
|
Loading…
Reference in New Issue
Block a user