summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHerb Lewis <herb@samba.org>2003-01-15 16:41:29 +0000
committerHerb Lewis <herb@samba.org>2003-01-15 16:41:29 +0000
commit6999ff1d484ea8f1957b3479b24ec3fea228fdd0 (patch)
treeee9998b4d17c9e740625815429b0c744e2dc5ae1
parente4819ee88bfcdd90845bcbfbe8912afcb1095367 (diff)
downloadsamba-6999ff1d484ea8f1957b3479b24ec3fea228fdd0.tar.gz
samba-6999ff1d484ea8f1957b3479b24ec3fea228fdd0.tar.bz2
samba-6999ff1d484ea8f1957b3479b24ec3fea228fdd0.zip
initialize acct_ctrl variable before it is used
remove ldap_msgfree(result); as result is unitialized at this point (This used to be commit 1102a6f8cdf295d564df5447a223b354be72895d)
-rw-r--r--source3/passdb/pdb_ldap.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/source3/passdb/pdb_ldap.c b/source3/passdb/pdb_ldap.c
index 7c3c6f1f1f..7e443a97c6 100644
--- a/source3/passdb/pdb_ldap.c
+++ b/source3/passdb/pdb_ldap.c
@@ -907,7 +907,7 @@ static BOOL init_sam_from_ldap (struct ldapsam_privates *ldap_state,
group_rid;
uint8 smblmpwd[LM_HASH_LEN],
smbntpwd[NT_HASH_LEN];
- uint16 acct_ctrl,
+ uint16 acct_ctrl = 0,
logon_divs;
uint32 hours_len;
uint8 hours[MAX_HOURS_LEN];
@@ -1787,7 +1787,6 @@ static NTSTATUS ldapsam_update_sam_account(struct pdb_methods *my_methods, SAM_A
if (!init_ldap_from_sam(ldap_state, &mods, LDAP_MOD_REPLACE, False, newpwd)) {
DEBUG(0, ("ldapsam_update_sam_account: init_ldap_from_sam failed!\n"));
- ldap_msgfree(result);
return NT_STATUS_UNSUCCESSFUL;
}