1
0
mirror of https://github.com/samba-team/samba.git synced 2025-10-28 03:33:13 +03:00

r13247: Try to make better use of talloc in the auth/ and auth/gensec code.

We don't want temporary memory hanging around on the long-term
contexts.

Andrew Bartlett
This commit is contained in:
Andrew Bartlett
2006-01-31 01:50:54 +00:00
committed by Gerald (Jerry) Carter
parent fc045b42c2
commit 85b3f6ebdd
3 changed files with 35 additions and 17 deletions

View File

@@ -616,14 +616,14 @@ NTSTATUS sam_get_server_info_principal(TALLOC_CTX *mem_ctx, const char *principa
return nt_status;
}
nt_status = authsam_make_server_info(mem_ctx, sam_ctx, msgs[0], msgs_domain_ref[0],
nt_status = authsam_make_server_info(tmp_ctx, sam_ctx, msgs[0], msgs_domain_ref[0],
user_sess_key, lm_sess_key,
server_info);
if (!NT_STATUS_IS_OK(nt_status)) {
talloc_free(tmp_ctx);
return nt_status;
if (NT_STATUS_IS_OK(nt_status)) {
talloc_steal(mem_ctx, *server_info);
}
return NT_STATUS_OK;
talloc_free(tmp_ctx);
return nt_status;
}
static NTSTATUS authsam_check_password_internals(struct auth_method_context *ctx,