From: Simon Tatham Date: Tue, 21 Nov 2000 10:53:10 +0000 (+0000) Subject: Fix segfault when you press a key before the SSH protocol decides whether X-Git-Tag: 0.51~12 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=d094883d3c13500631fed9ae8e9d016fb26d2676;p=PuTTY.git Fix segfault when you press a key before the SSH protocol decides whether it's doing SSH1 or SSH2. Only visible on slow servers :-) [originally from svn r803] --- diff --git a/ssh.c b/ssh.c index 26379e12..d2eb302c 100644 --- a/ssh.c +++ b/ssh.c @@ -2680,7 +2680,7 @@ static char *ssh_init (char *host, int port, char **realhost) { * Called to send data down the Telnet connection. */ static void ssh_send (char *buf, int len) { - if (s == NULL) + if (s == NULL || ssh_protocol == NULL) return; ssh_protocol(buf, len, 0);