mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-12-15 18:32:26 +03:00
getpass: Fixed a compiler warning.
This commit is contained in:
@@ -60,7 +60,9 @@ static int ssh_gets(const char *prompt, char *buf, size_t len, int verify) {
|
|||||||
fprintf(stdout, "%s", prompt);
|
fprintf(stdout, "%s", prompt);
|
||||||
}
|
}
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fgets(tmp, len, stdin);
|
if (fgets(tmp, len, stdin) == NULL) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
if ((ptr = strchr(tmp, '\n'))) {
|
if ((ptr = strchr(tmp, '\n'))) {
|
||||||
*ptr = '\0';
|
*ptr = '\0';
|
||||||
|
|||||||
Reference in New Issue
Block a user