summaryrefslogtreecommitdiff
path: root/compat.c
diff options
context:
space:
mode:
authordamien <damien>2000-05-30 03:44:51 +0000
committerdamien <damien>2000-05-30 03:44:51 +0000
commitda280636e37f44d19fe761a5ce568d50e5f3557a (patch)
treea86315928c635b373ab0d453bbd9140838f5fbe6 /compat.c
parent70190138f56ea277d12142acdc0b24939c4613ef (diff)
downloadopenssh-da280636e37f44d19fe761a5ce568d50e5f3557a.tar.gz
- OpenBSD CVS updates:
- markus@cvs.openbsd.org [session.c] make x11-fwd work w/ localhost (xauth add host/unix:11) [cipher.c compat.c readconf.c servconf.c] check strtok() != NULL; ok niels@ [key.c] fix key_read() for uuencoded keys w/o '=' [serverloop.c] group ssh1 vs. ssh2 in serverloop [kex.c kex.h myproposal.h sshconnect2.c sshd.c] split kexinit/kexdh, factor out common code [readconf.c ssh.1 ssh.c] forwardagent defaults to no, add ssh -A - theo@cvs.openbsd.org [session.c] just some line shortening
Diffstat (limited to 'compat.c')
-rw-r--r--compat.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/compat.c b/compat.c
index 00f031b8..967e0b6b 100644
--- a/compat.c
+++ b/compat.c
@@ -28,7 +28,7 @@
*/
#include "includes.h"
-RCSID("$Id: compat.c,v 1.10 2000/05/09 01:03:00 damien Exp $");
+RCSID("$Id: compat.c,v 1.11 2000/05/30 03:44:53 damien Exp $");
#include "ssh.h"
#include "packet.h"
@@ -80,10 +80,12 @@ compat_datafellows(const char *version)
int
proto_spec(const char *spec)
{
- char *s = xstrdup(spec);
- char *p;
+ char *s, *p;
int ret = SSH_PROTO_UNKNOWN;
+ if (spec == NULL)
+ return ret;
+ s = xstrdup(spec);
for ((p = strtok(s, SEP)); p; (p = strtok(NULL, SEP))) {
switch(atoi(p)) {
case 1: