Commit 6e98229d authored by Jerome PERALDI's avatar Jerome PERALDI Committed by Vijay C

bug #127339 - [OAI] [NR UE SOFTMODEM] bad pointer initialisation after W02 rebase code

parent 117f9602
......@@ -1361,6 +1361,14 @@ static bool pdcp_data_req_srb(protocol_ctxt_t *ctxt_pP,
LOG_E(PDCP, "%s:%d:%s: fatal\n", __FILE__, __LINE__, __FUNCTION__);
exit(1);
}
nr_pdcp_manager_lock(nr_pdcp_ue_manager);
ue = nr_pdcp_manager_get_ue(nr_pdcp_ue_manager, ue_id);
if (rb_id < 1 || rb_id > 2)
rb = NULL;
else
rb = ue->srb[rb_id - 1];
/** TRACE PDCP PDU */
if (NULL != ue && NULL != rb) {
......@@ -1382,14 +1390,6 @@ static bool pdcp_data_req_srb(protocol_ctxt_t *ctxt_pP,
LOG_PDCP_P(OAILOG_INFO, "DL_PDCP_PDU", -1, -1, (pdcp_pkt), (unsigned char *)sdu_buffer, sdu_buffer_size);
}
nr_pdcp_manager_lock(nr_pdcp_ue_manager);
ue = nr_pdcp_manager_get_ue(nr_pdcp_ue_manager, ue_id);
if (rb_id < 1 || rb_id > 2)
rb = NULL;
else
rb = ue->srb[rb_id - 1];
if (rb == NULL) {
LOG_E(PDCP, "%s:%d:%s: no SRB found (ue_id %ld, rb_id %ld)\n", __FILE__, __LINE__, __FUNCTION__, ue_id, rb_id);
......@@ -1397,8 +1397,8 @@ static bool pdcp_data_req_srb(protocol_ctxt_t *ctxt_pP,
return 0;
}
rb->recv_sdu(rb, (char *)sdu_buffer, sdu_buffer_size, muiP);
rb->recv_sdu(rb, (char *)sdu_buffer, sdu_buffer_size, muiP);
nr_pdcp_manager_unlock(nr_pdcp_ue_manager);
return 1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment