diff options
Diffstat (limited to 'source4/auth/system_session.c')
-rw-r--r-- | source4/auth/system_session.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/source4/auth/system_session.c b/source4/auth/system_session.c index 3b9edd779df..4c5290db71a 100644 --- a/source4/auth/system_session.c +++ b/source4/auth/system_session.c @@ -51,7 +51,12 @@ _PUBLIC_ struct auth_session_info *system_session(struct loadparm_context *lp_ct return static_session; } - nt_status = auth_system_session_info(talloc_autofree_context(), + /* + * Use NULL here, not the autofree context for this + * static pointer. The destructor prevents freeing this + * memory anyway. + */ + nt_status = auth_system_session_info(NULL, lp_ctx, &static_session); if (!NT_STATUS_IS_OK(nt_status)) { |