bugfix: off-by-one in span assignment

The test in _check_spanno_and_basechan() was off by one
(used '<' instead of '<=')

Signed-off-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com>
Acked-by: Shaun Ruffell <sruffell@digium.com>

git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@10327 a0bf4364-ded3-4de4-8d8a-66a801d63aff
This commit is contained in:
Tzafrir Cohen 2011-11-07 17:33:25 +00:00
parent 382125f880
commit 875c1ec3b6

View File

@ -6751,7 +6751,7 @@ _check_spanno_and_basechan(struct dahdi_span *span, u32 spanno, u32 basechan)
if (next_channo == -1) if (next_channo == -1)
break; break;
if ((basechan + span->channels) < next_channo) if ((basechan + span->channels) <= next_channo)
break; break;
/* Cannot fit the span into the requested location. Abort. */ /* Cannot fit the span into the requested location. Abort. */