Fix off-by-one error.
Obtained from: OpenBSD
This commit is contained in:
parent
c794254d96
commit
d96f3089f2
@ -151,7 +151,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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user