diff options
Diffstat (limited to 'ssh-keyscan.c')
-rw-r--r-- | ssh-keyscan.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ssh-keyscan.c b/ssh-keyscan.c index e59eacace..989f7ecce 100644 --- a/ssh-keyscan.c +++ b/ssh-keyscan.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: ssh-keyscan.c,v 1.97 2015/01/28 21:15:47 djm Exp $ */ | 1 | /* $OpenBSD: ssh-keyscan.c,v 1.98 2015/01/30 01:13:33 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright 1995, 1996 by David Mazieres <dm@lcs.mit.edu>. | 3 | * Copyright 1995, 1996 by David Mazieres <dm@lcs.mit.edu>. |
4 | * | 4 | * |
@@ -466,7 +466,8 @@ congreet(int s) | |||
466 | return; | 466 | return; |
467 | } | 467 | } |
468 | *cp = '\0'; | 468 | *cp = '\0'; |
469 | c->c_ssh = ssh_packet_set_connection(NULL, s, s); | 469 | if ((c->c_ssh = ssh_packet_set_connection(NULL, s, s)) == NULL) |
470 | fatal("ssh_packet_set_connection failed"); | ||
470 | ssh_set_app_data(c->c_ssh, c); /* back link */ | 471 | ssh_set_app_data(c->c_ssh, c); /* back link */ |
471 | if (sscanf(buf, "SSH-%d.%d-%[^\n]\n", | 472 | if (sscanf(buf, "SSH-%d.%d-%[^\n]\n", |
472 | &remote_major, &remote_minor, remote_version) == 3) | 473 | &remote_major, &remote_minor, remote_version) == 3) |