summaryrefslogtreecommitdiff
path: root/ssh-keyscan.c
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2001-09-12 17:10:40 +0000
committerBen Lindstrom <mouring@eviladmin.org>2001-09-12 17:10:40 +0000
commit78bbd9ebe348a4dc5dda23db4e281d90eeef85d5 (patch)
treea767e9c96116d03ef26a492d7b938250b52a2376 /ssh-keyscan.c
parent8d066fb262af638d0110437afa794ce46387e0dd (diff)
downloadopenssh-git-78bbd9ebe348a4dc5dda23db4e281d90eeef85d5.tar.gz
- danh@cvs.openbsd.org 2001/08/27 22:02:13
[ssh-keyscan.c] fix memory fault if non-existent filename is given to the -f option ok markus@
Diffstat (limited to 'ssh-keyscan.c')
-rw-r--r--ssh-keyscan.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/ssh-keyscan.c b/ssh-keyscan.c
index 3f8c5b40..9a9b72f4 100644
--- a/ssh-keyscan.c
+++ b/ssh-keyscan.c
@@ -7,7 +7,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: ssh-keyscan.c,v 1.27 2001/08/05 23:29:58 markus Exp $");
+RCSID("$OpenBSD: ssh-keyscan.c,v 1.28 2001/08/27 22:02:13 danh Exp $");
#if defined(HAVE_SYS_QUEUE_H) && !defined(HAVE_BOGUS_SYS_QUEUE_H)
#include <sys/queue.h>
@@ -786,6 +786,8 @@ main(int argc, char **argv)
for (j = 0; j < fopt_count; j++) {
lb = Linebuf_alloc(argv[j], error);
+ if (!lb)
+ continue;
while ((line = Linebuf_getline(lb)) != NULL)
do_host(line);
Linebuf_free(lb);