* src/main.c (promt_for_password): Avoid getpass() when fuzzing

This commit is contained in:
Tim Rühsen 2018-04-17 12:15:18 +02:00
parent 3ceb6e5630
commit fbb4cd231e

View File

@ -1072,7 +1072,12 @@ prompt_for_password (void)
fprintf (stderr, _("Password for user %s: "), quote (opt.user));
else
fprintf (stderr, _("Password: "));
#ifndef TESTING
/* gnulib's getpass() uses static variables internally, bad for fuzing */
return getpass("");
#else
return xstrdup("");
#endif
}