diff --git a/lib/include/srslte/upper/rlc_am_lte.h b/lib/include/srslte/upper/rlc_am_lte.h index e8536f42a..d4039be68 100644 --- a/lib/include/srslte/upper/rlc_am_lte.h +++ b/lib/include/srslte/upper/rlc_am_lte.h @@ -134,9 +134,11 @@ public: } void clear_pdcp_sdu(uint32_t sn) { - uint32_t sn_idx = get_idx(sn); + uint32_t sn_idx = get_idx(sn); + buffered_pdus[sn_idx].sn = invalid_sn; + buffered_pdus[sn_idx].fully_acked = false; + buffered_pdus[sn_idx].fully_txed = false; buffered_pdus[sn_idx].rlc_sn_info_list.clear(); - buffered_pdus[sn_idx].sn = invalid_sn; count--; } diff --git a/lib/src/upper/rlc_am_lte.cc b/lib/src/upper/rlc_am_lte.cc index 397f9b0c4..44f67a460 100644 --- a/lib/src/upper/rlc_am_lte.cc +++ b/lib/src/upper/rlc_am_lte.cc @@ -2018,15 +2018,17 @@ const size_t buffered_pdcp_pdu_list::max_buffer_idx; buffered_pdcp_pdu_list::buffered_pdcp_pdu_list() : buffered_pdus(max_buffer_idx + 1) { for (size_t i = 0; i < buffered_pdus.size(); ++i) { - buffered_pdus[i].sn = invalid_sn; buffered_pdus[i].rlc_sn_info_list.reserve(5); } + clear(); } void buffered_pdcp_pdu_list::clear() { for (auto& b : buffered_pdus) { - b.sn = invalid_sn; + b.sn = invalid_sn; + b.fully_acked = false; + b.fully_txed = false; b.rlc_sn_info_list.clear(); } }