mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-13 15:50:59 +00:00
fix event system
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@1043 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
ef4556479b
commit
cf16ac34a9
@ -155,12 +155,15 @@ static void *SWITCH_THREAD_FUNC switch_event_thread(switch_thread *thread, void
|
||||
queues[0] = EVENT_QUEUE[SWITCH_PRIORITY_HIGH];
|
||||
queues[1] = EVENT_QUEUE[SWITCH_PRIORITY_NORMAL];
|
||||
queues[2] = EVENT_QUEUE[SWITCH_PRIORITY_LOW];
|
||||
|
||||
for(;;) {
|
||||
len[1] = switch_queue_size(EVENT_QUEUE[SWITCH_PRIORITY_NORMAL]);
|
||||
len[2] = switch_queue_size(EVENT_QUEUE[SWITCH_PRIORITY_LOW]);
|
||||
len[0] = switch_queue_size(EVENT_QUEUE[SWITCH_PRIORITY_HIGH]);
|
||||
|
||||
while (THREAD_RUNNING == 1 ||
|
||||
(len[1] = switch_queue_size(EVENT_QUEUE[SWITCH_PRIORITY_NORMAL])) ||
|
||||
(len[2] = switch_queue_size(EVENT_QUEUE[SWITCH_PRIORITY_LOW])) ||
|
||||
(len[0] = switch_queue_size(EVENT_QUEUE[SWITCH_PRIORITY_HIGH]))
|
||||
) {
|
||||
if (THREAD_RUNNING != 1 && !len[0] && !len[1] && !len[2]) {
|
||||
break;
|
||||
}
|
||||
|
||||
for(i = 0; i < 3; i++) {
|
||||
if (len[i]) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user