clear event queue on shutdown
This commit is contained in:
parent
2d811e0ba0
commit
0449baca59
|
@ -194,6 +194,12 @@ static void *SWITCH_THREAD_FUNC switch_scheduler_task_thread(switch_thread_t *th
|
|||
task_thread_loop(1);
|
||||
|
||||
switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_NOTICE, "Task thread ending\n");
|
||||
|
||||
while(switch_queue_trypop(globals.event_queue, &pop) == SWITCH_STATUS_SUCCESS) {
|
||||
switch_event_t *event = (switch_event_t *) pop;
|
||||
switch_event_destroy(&event);
|
||||
}
|
||||
|
||||
globals.task_thread_running = 0;
|
||||
|
||||
return NULL;
|
||||
|
|
Loading…
Reference in New Issue