summaryrefslogtreecommitdiff
path: root/source3/smbd/uid.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd/uid.c')
-rw-r--r--source3/smbd/uid.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/source3/smbd/uid.c b/source3/smbd/uid.c
index dceea450e6..1a3b7383c9 100644
--- a/source3/smbd/uid.c
+++ b/source3/smbd/uid.c
@@ -387,7 +387,12 @@ static void pop_conn_ctx(void)
void become_root(void)
{
- push_sec_ctx();
+ /*
+ * no good way to handle push_sec_ctx() failing without changing
+ * the prototype of become_root()
+ */
+ if (!push_sec_ctx())
+ return;
push_conn_ctx();
set_root_sec_ctx();
}