sulogin: add missing ifdefs
Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
parent
286865bf7e
commit
d3f77b4b8b
|
@ -775,8 +775,10 @@ quit:
|
||||||
tcfinal(con);
|
tcfinal(con);
|
||||||
printf("\r\n");
|
printf("\r\n");
|
||||||
out:
|
out:
|
||||||
|
#ifdef HAVE_EXPLICIT_BZERO
|
||||||
if (ret == NULL)
|
if (ret == NULL)
|
||||||
explicit_bzero(pass, sizeof(pass));
|
explicit_bzero(pass, sizeof(pass));
|
||||||
|
#endif
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1055,7 +1057,9 @@ int main(int argc, char **argv)
|
||||||
if ((answer = getpasswd(con)) == NULL)
|
if ((answer = getpasswd(con)) == NULL)
|
||||||
break;
|
break;
|
||||||
if (deny) {
|
if (deny) {
|
||||||
|
#ifdef HAVE_EXPLICIT_BZERO
|
||||||
explicit_bzero(answer, SULOGIN_PASSWORD_BUFSIZ);
|
explicit_bzero(answer, SULOGIN_PASSWORD_BUFSIZ);
|
||||||
|
#endif
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1070,9 +1074,9 @@ int main(int argc, char **argv)
|
||||||
else if (strcmp(cryptbuf, pwd->pw_passwd) == 0)
|
else if (strcmp(cryptbuf, pwd->pw_passwd) == 0)
|
||||||
doshell++;
|
doshell++;
|
||||||
}
|
}
|
||||||
|
#ifdef HAVE_EXPLICIT_BZERO
|
||||||
explicit_bzero(answer, SULOGIN_PASSWORD_BUFSIZ);
|
explicit_bzero(answer, SULOGIN_PASSWORD_BUFSIZ);
|
||||||
|
#endif
|
||||||
if (doshell) {
|
if (doshell) {
|
||||||
/* sushell() unmask signals */
|
/* sushell() unmask signals */
|
||||||
sushell(pwd);
|
sushell(pwd);
|
||||||
|
|
Loading…
Reference in New Issue