summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2006-02-17 15:51:25 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 11:10:11 -0500
commit5f8a70d01e113838594b3cbe9314d04a9539ee37 (patch)
treeb2ec81f0ea3d383157c46f4dc035b1c570c5cb2a
parent14c4d535d25250f9535b66e68cff169300739f78 (diff)
downloadsamba-5f8a70d01e113838594b3cbe9314d04a9539ee37.tar.gz
samba-5f8a70d01e113838594b3cbe9314d04a9539ee37.tar.bz2
samba-5f8a70d01e113838594b3cbe9314d04a9539ee37.zip
r13542: Don't reuse a pointer we just freed (Doh!).
Jeremy. (This used to be commit e755155b0e665cb6d10c28fe7fc6c1f6699d18e6)
-rw-r--r--source3/passdb/secrets.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/passdb/secrets.c b/source3/passdb/secrets.c
index f6b1ece7d4..55fb0cfc0e 100644
--- a/source3/passdb/secrets.c
+++ b/source3/passdb/secrets.c
@@ -1051,6 +1051,8 @@ BOOL secrets_restore_schannel_session_info(TALLOC_CTX *mem_ctx,
&pdc->domain);
if (ret == -1 || l1 != 8 || l2 != 8 || l3 != 8 || l4 != 16 || l5 != 16) {
+ /* Bad record - delete it. */
+ tdb_delete_bystring(tdb_sc, keystr);
talloc_free(keystr);
talloc_free(pdc);
SAFE_FREE(pseed_chal);
@@ -1059,8 +1061,6 @@ BOOL secrets_restore_schannel_session_info(TALLOC_CTX *mem_ctx,
SAFE_FREE(psess_key);
SAFE_FREE(pmach_pw);
SAFE_FREE(value.dptr);
- /* Bad record - delete it. */
- tdb_delete_bystring(tdb_sc, keystr);
return False;
}