1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-25 23:21:54 +03:00

s3/passdb: clang: Fix warning: Value stored to 'acct_ctrl' is never read

Fixes:

source3/passdb/pdb_ldap.c:922:3: warning: Value stored to 'acct_ctrl' is never read <--[clang]
                acct_ctrl |= ACB_NORMAL;
                ^            ~~~~~~~~~~

Signed-off-by: Noel Power <noel.power@suse.com>
Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
Noel Power 2019-09-06 13:46:40 +00:00 committed by Jeremy Allison
parent 6ae0fd5a34
commit 388f280448

View File

@ -491,7 +491,6 @@ static bool init_sam_from_ldap(struct ldapsam_privates *ldap_state,
uint8_t smblmpwd[LM_HASH_LEN],
smbntpwd[NT_HASH_LEN];
bool use_samba_attrs = True;
uint32_t acct_ctrl = 0;
uint16_t logon_divs;
uint16_t bad_password_count = 0,
logon_count = 0;
@ -911,6 +910,7 @@ static bool init_sam_from_ldap(struct ldapsam_privates *ldap_state,
LDAP_ATTR_ACB_INFO),
ctx);
if (temp) {
uint32_t acct_ctrl = 0;
acct_ctrl = pdb_decode_acct_ctrl(temp);
if (acct_ctrl == 0) {
@ -918,8 +918,6 @@ static bool init_sam_from_ldap(struct ldapsam_privates *ldap_state,
}
pdb_set_acct_ctrl(sampass, acct_ctrl, PDB_SET);
} else {
acct_ctrl |= ACB_NORMAL;
}
pdb_set_hours_len(sampass, hours_len, PDB_SET);