summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xzaptel.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/zaptel.c b/zaptel.c
index f394d24..062927c 100755
--- a/zaptel.c
+++ b/zaptel.c
@@ -639,7 +639,7 @@ static void __qevent(struct zt_chan *chan, int event)
if ((chan->eventoutidx == 0) && (chan->eventinidx == (ZT_MAX_EVENTSIZE - 1)))
return;
/* if full, ignore */
- if (chan->eventoutidx == (chan->eventinidx - 1)) return;
+ if (chan->eventinidx == (chan->eventoutidx - 1)) return;
/* save the event */
chan->eventbuf[chan->eventinidx++] = event;
/* wrap the index, if necessary */