mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-31 06:15:37 +00:00
Quiet a false positive found by several static analysis tools.
These tools don't know that log_error() does not return (it longjmps to error_jmp which returns to the sudo front-end).
This commit is contained in:
@@ -797,7 +797,7 @@ init_vars(char * const envp[])
|
||||
* can read the shadow passwd file if necessary.
|
||||
*/
|
||||
if ((sudo_user.pw = sudo_getpwnam(user_name)) == NULL) {
|
||||
struct passwd pw;
|
||||
static struct passwd pw;
|
||||
|
||||
/* Create a fake struct passwd for log_error(). */
|
||||
memset(&pw, 0, sizeof(pw));
|
||||
|
Reference in New Issue
Block a user