diff options
author | Niels Provos <provos@cvs.openbsd.org> | 2000-06-25 20:17:58 +0000 |
---|---|---|
committer | Niels Provos <provos@cvs.openbsd.org> | 2000-06-25 20:17:58 +0000 |
commit | d8b892a172d30a147d88811967df87480333b076 (patch) | |
tree | 5879d82b6ac119e29fb140741fa2116612dfbe1c /usr.bin/ssh | |
parent | 75c37780ee8e8b8f63200abbf2850b9fedf748bb (diff) |
correct check for bad channel ids; from Wei Dai <weidai@eskimo.com>
Diffstat (limited to 'usr.bin/ssh')
-rw-r--r-- | usr.bin/ssh/channels.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/ssh/channels.c b/usr.bin/ssh/channels.c index 15484fa2913..5ee5624eca4 100644 --- a/usr.bin/ssh/channels.c +++ b/usr.bin/ssh/channels.c @@ -17,7 +17,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: channels.c,v 1.62 2000/06/20 01:39:39 markus Exp $"); +RCSID("$OpenBSD: channels.c,v 1.63 2000/06/25 20:17:57 provos Exp $"); #include "ssh.h" #include "packet.h" @@ -135,7 +135,7 @@ Channel * channel_lookup(int id) { Channel *c; - if (id < 0 && id > channels_alloc) { + if (id < 0 || id > channels_alloc) { log("channel_lookup: %d: bad id", id); return NULL; } |