From 9c0590cbca8128a76300d0e5b3f5b8e479d8080f Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Mon, 10 Dec 2007 11:47:17 +0100 Subject: [PATCH] Correctly unbecome_root() on error --- source/auth/auth_util.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/auth/auth_util.c b/source/auth/auth_util.c index 6fbec48894a..32224fa2199 100644 --- a/source/auth/auth_util.c +++ b/source/auth/auth_util.c @@ -956,6 +956,7 @@ static struct nt_user_token *create_local_nt_token(TALLOC_CTX *mem_ctx, status = add_aliases(get_global_sam_sid(), result); if (!NT_STATUS_IS_OK(status)) { + unbecome_root(); TALLOC_FREE(result); return NULL; } @@ -965,6 +966,7 @@ static struct nt_user_token *create_local_nt_token(TALLOC_CTX *mem_ctx, status = add_aliases(&global_sid_Builtin, result); if (!NT_STATUS_IS_OK(status)) { + unbecome_root(); TALLOC_FREE(result); return NULL; } -- 2.11.4.GIT