From 387f87aa83473947c8e9a9ac0eb929b1cbd43c76 Mon Sep 17 00:00:00 2001 From: Xavier Arteaga Date: Fri, 17 Nov 2017 14:15:08 +0100 Subject: [PATCH] Solved Segfault --- srsue/src/phy/prach.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/srsue/src/phy/prach.cc b/srsue/src/phy/prach.cc index bd7550457..62b32e62f 100644 --- a/srsue/src/phy/prach.cc +++ b/srsue/src/phy/prach.cc @@ -49,8 +49,10 @@ prach::~prach() { free(buffer[i]); } } - if (signal_buffer) { - free(signal_buffer); + for (uint32_t p = 0; p < SRSLTE_MAX_PORTS; p++) { + if (signal_buffer[p]) { + free(signal_buffer[p]); + } } srslte_cfo_free(&cfo_h); srslte_prach_free(&prach_obj);