From 004d6d3bab05dc124134f26c639f52bc037e3735 Mon Sep 17 00:00:00 2001 From: Robert Schmidt Date: Thu, 30 Jun 2022 12:17:15 +0200 Subject: [PATCH] Correctly stop tx_reorder and L1_stats threads --- executables/nr-gnb.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/executables/nr-gnb.c b/executables/nr-gnb.c index 388d701b83..0bac9ce3eb 100644 --- a/executables/nr-gnb.c +++ b/executables/nr-gnb.c @@ -482,6 +482,11 @@ void term_gNB_Tpool(int inst) { abortNotifiedFIFO(&gNB->L1_tx_free); abortNotifiedFIFO(&gNB->L1_tx_filled); abortNotifiedFIFO(&gNB->L1_tx_out); + + gNB_L1_proc_t *proc = &gNB->proc; + if (!get_softmodem_params()->emulate_l1) + pthread_join(proc->L1_stats_thread, NULL); + pthread_join(proc->pthread_tx_reorder, NULL); } /*!