diff options
author | Ben Lindstrom <mouring@eviladmin.org> | 2001-09-12 18:05:05 +0000 |
---|---|---|
committer | Ben Lindstrom <mouring@eviladmin.org> | 2001-09-12 18:05:05 +0000 |
commit | 520b55c8c410061c9a16417a6ec879967b1ea95a (patch) | |
tree | 80f4976d5e5e53580455f71fd8916e46036c24f4 /ssh-keyscan.c | |
parent | d71ba5771b5c67b4efd3294ecb85dc4d10d03265 (diff) | |
download | openssh-git-520b55c8c410061c9a16417a6ec879967b1ea95a.tar.gz |
- markus@cvs.openbsd.org 2001/08/30 22:22:32
[ssh-keyscan.c]
do not pass pointers to longjmp; fix from wayne@blorf.net
Diffstat (limited to 'ssh-keyscan.c')
-rw-r--r-- | ssh-keyscan.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/ssh-keyscan.c b/ssh-keyscan.c index 9a9b72f4..ad627bb9 100644 --- a/ssh-keyscan.c +++ b/ssh-keyscan.c @@ -7,7 +7,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: ssh-keyscan.c,v 1.28 2001/08/27 22:02:13 danh Exp $"); +RCSID("$OpenBSD: ssh-keyscan.c,v 1.29 2001/08/30 22:22:32 markus Exp $"); #if defined(HAVE_SYS_QUEUE_H) && !defined(HAVE_BOGUS_SYS_QUEUE_H) #include <sys/queue.h> @@ -68,6 +68,7 @@ size_t read_wait_size; int ncon; int nonfatal_fatal = 0; jmp_buf kexjmp; +Key *kexjmp_key; /* * Keep a connection structure for each file descriptor. The state @@ -322,7 +323,8 @@ keygrab_ssh1(con *c) static int hostjump(Key *hostkey) { - longjmp(kexjmp, (int)hostkey); + kexjmp_key = hostkey; + longjmp(kexjmp, 1); } static int @@ -363,10 +365,8 @@ keygrab_ssh2(con *c) xfree(c->c_kex); c->c_kex = NULL; packet_close(); - if (j < 0) - j = 0; - return (Key*)(j); + return j < 0? NULL : kexjmp_key; } static void |