mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-07-28 01:41:48 +03:00
examples: Use ssh_getpass().
This commit is contained in:
@ -58,7 +58,10 @@ static int auth_callback(const char *prompt, char *buf, size_t len,
|
||||
*ptr = '\0';
|
||||
}
|
||||
} else {
|
||||
answer = getpass(prompt);
|
||||
if (ssh_getpass(prompt, buf, len, 0, 0) < 0) {
|
||||
return -1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (answer == NULL) {
|
||||
|
Reference in New Issue
Block a user