ue_stack: only push sync event to event queue is stack is still running

stopping the UE in ZMQ mode caused a dead-lock because the Stack was
stopped before the PHY causing the sync queue to overflow. Since we
use a queue-length of 1 in ZMQ, mode, the PHY sync thread was blocking to
push a new sync event while the stack thread was already stopped.

this patch makes sure no new sync events are queued after the stack has
been terminated.
master
Andre Puschmann 4 years ago
parent aec18a93d1
commit c16ac6c890

@ -269,7 +269,9 @@ void ue_stack_lte::out_of_sync()
void ue_stack_lte::run_tti(uint32_t tti, uint32_t tti_jump) void ue_stack_lte::run_tti(uint32_t tti, uint32_t tti_jump)
{ {
sync_task_queue.push([this, tti, tti_jump]() { run_tti_impl(tti, tti_jump); }); if (running) {
sync_task_queue.push([this, tti, tti_jump]() { run_tti_impl(tti, tti_jump); });
}
} }
void ue_stack_lte::run_tti_impl(uint32_t tti, uint32_t tti_jump) void ue_stack_lte::run_tti_impl(uint32_t tti, uint32_t tti_jump)

Loading…
Cancel
Save