- truncate the echoed string at the newline, not at the first non-cr/lf
This commit is contained in:
parent
147635188d
commit
56d1413f95
@ -441,7 +441,7 @@ When enabled, ftpd, krshd, and login.krb5 gain dependence on libpam.
|
||||
+ if (message->msg_style == PAM_PROMPT_ECHO_ON) {
|
||||
+ if (fgets(pwbuf, sizeof(pwbuf),
|
||||
+ stdin) != NULL) {
|
||||
+ pwbuf[strspn(pwbuf, "\r\n")] = '\0';
|
||||
+ pwbuf[strcspn(pwbuf, "\r\n")] = '\0';
|
||||
+ pwstring = pwbuf;
|
||||
+ }
|
||||
+ } else {
|
||||
|
Loading…
Reference in New Issue
Block a user