From 5472b1751645f750e42a0ba6daac667983b1a56c Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Fri, 24 Jan 2020 11:13:55 -0700 Subject: [PATCH] Fix crash in sudo 1.8.30 when suspending sudo at the password prompt. The closure pointer in sudo_conv_callback was being filled in with a struct getpass_closure ** instead of a struct getpass_closure *. The bug was introduced in the fix for Bug #910; previously the closure variable was a struct getpass_closure, not a pointer. Fix from Michael Norton; Bug #914. --- plugins/sudoers/check.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/sudoers/check.c b/plugins/sudoers/check.c index 72e87eef6..9b03c7a05 100644 --- a/plugins/sudoers/check.c +++ b/plugins/sudoers/check.c @@ -108,7 +108,7 @@ check_user_interactive(int validated, int mode, struct getpass_closure *closure) /* Construct callback for getpass function. */ memset(&cb, 0, sizeof(cb)); cb.version = SUDO_CONV_CALLBACK_VERSION; - cb.closure = &closure; + cb.closure = closure; cb.on_suspend = getpass_suspend; cb.on_resume = getpass_resume; callback = &cb; -- 2.25.1