summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--channels/chan_zap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/channels/chan_zap.c b/channels/chan_zap.c
index c48f811a8..aa81a1e51 100644
--- a/channels/chan_zap.c
+++ b/channels/chan_zap.c
@@ -1148,7 +1148,7 @@ static int alloc_sub(struct zt_pvt *p, int x)
{
ZT_BUFFERINFO bi;
int res;
- if (p->subs[x].zfd < 0) {
+ if (p->subs[x].zfd >= 0) {
ast_log(LOG_WARNING, "%s subchannel of %d already in use\n", subnames[x], p->channel);
return -1;
}