From b0589451428a26a5f772334e3935a858f27c17ee Mon Sep 17 00:00:00 2001 From: faluco Date: Tue, 26 Oct 2021 12:07:36 +0200 Subject: [PATCH] Fix data race in sync::current_earfcn. --- srsue/src/phy/sync.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/srsue/src/phy/sync.cc b/srsue/src/phy/sync.cc index e799fb96f..270bf03ce 100644 --- a/srsue/src/phy/sync.cc +++ b/srsue/src/phy/sync.cc @@ -944,6 +944,7 @@ void sync::get_current_cell(srsran_cell_t* cell_, uint32_t* earfcn_) *cell_ = cell.get(); } if (earfcn_) { + std::unique_lock ul(rrc_mutex); *earfcn_ = current_earfcn; } }