From: Jeff Peeler Date: Thu, 3 Feb 2011 20:43:59 +0000 (+0000) Subject: Fix no MOH and frame queueing problem for parked calls. X-Git-Tag: 1.4.41-rc1~15 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a7d12781c014416fd903f25fb11b78068f907393;p=thirdparty%2Fasterisk.git Fix no MOH and frame queueing problem for parked calls. This was a regression introduced when select was changed to poll and was just a conversion error: POLLPRI detects OOB data, not POLLERR. (closes issue #18637) Reported by: jvandal git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@306120 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/res/res_features.c b/res/res_features.c index e04ac7c26e..76fcec2afa 100644 --- a/res/res_features.c +++ b/res/res_features.c @@ -2764,12 +2764,12 @@ static void *do_parking_thread(void *ignore) continue; } - if (!(fds[y].revents & (POLLIN | POLLERR))) { + if (!(fds[y].revents & (POLLIN | POLLERR | POLLPRI))) { /* Next x */ continue; } - if (fds[y].revents & POLLERR) { + if (fds[y].revents & POLLPRI) { ast_set_flag(chan, AST_FLAG_EXCEPTION); } else { ast_clear_flag(chan, AST_FLAG_EXCEPTION); @@ -2835,7 +2835,7 @@ std: for (x = 0; x < AST_MAX_FDS; x++) { /* mark fds for next round */ } new_fds = tmp; new_fds[new_nfds].fd = chan->fds[x]; - new_fds[new_nfds].events = POLLIN | POLLERR; + new_fds[new_nfds].events = POLLIN | POLLERR | POLLPRI; new_fds[new_nfds].revents = 0; new_nfds++; }