- Fix a race condition where the prach struct was being free while the prach worker was still running.

This could cause heap corruption making the enb_phy_test to fail sometimes.
This commit is contained in:
faluco 2020-07-31 12:27:40 +02:00 committed by faluco
parent 5867668c0c
commit 0a01bd4e1b
1 changed files with 2 additions and 2 deletions

View File

@ -72,12 +72,12 @@ int prach_worker::init(const srslte_cell_t& cell_,
void prach_worker::stop()
{
srslte_prach_free(&prach);
running = false;
sf_buffer* s = nullptr;
pending_buffers.push(s);
wait_thread_finish();
srslte_prach_free(&prach);
}
void prach_worker::set_max_prach_offset_us(float delay_us)