Reflect the SSH_SERVER_NOT_KNOWN add-on in sample
Этот коммит содержится в:
родитель
d5b6f6cc37
Коммит
1301864f92
4
sample.c
4
sample.c
@ -469,6 +469,10 @@ int main(int argc, char **argv){
|
|||||||
ssh_disconnect(session);
|
ssh_disconnect(session);
|
||||||
ssh_finalize();
|
ssh_finalize();
|
||||||
exit(-1);
|
exit(-1);
|
||||||
|
case SSH_SERVER_FILE_NOT_FOUND:
|
||||||
|
fprintf(stderr,"Could not find known host file. If you accept the host key here,\n");
|
||||||
|
fprintf(stderr,"the file will be automatically created.\n");
|
||||||
|
/* fallback to SSH_SERVER_NOT_KNOWN behaviour */
|
||||||
case SSH_SERVER_NOT_KNOWN:
|
case SSH_SERVER_NOT_KNOWN:
|
||||||
hexa = ssh_get_hexa(hash, hlen);
|
hexa = ssh_get_hexa(hash, hlen);
|
||||||
free(hash);
|
free(hash);
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user