fix SegmentFault by harq_pid==8 after clean_dlsch_eNB
This commit is contained in:
@@ -2064,6 +2064,10 @@ int dlsch_modulation(PHY_VARS_eNB* phy_vars_eNB,
|
||||
if ((dlsch0 != NULL) && (dlsch1 != NULL)){
|
||||
|
||||
harq_pid = dlsch0->harq_ids[frame%2][subframe_offset];
|
||||
if(harq_pid >= dlsch0->Mdlharq) {
|
||||
LOG_E(PHY,"illegal harq_pid %d\n", harq_pid);
|
||||
return(-1);
|
||||
}
|
||||
dlsch0_harq = dlsch0->harq_processes[harq_pid];
|
||||
mimo_mode = dlsch0_harq->mimo_mode;
|
||||
mod_order0 = dlsch0_harq->Qm;
|
||||
@@ -2081,6 +2085,10 @@ int dlsch_modulation(PHY_VARS_eNB* phy_vars_eNB,
|
||||
}else if ((dlsch0 != NULL) && (dlsch1 == NULL)){
|
||||
|
||||
harq_pid = dlsch0->harq_ids[frame%2][subframe_offset];
|
||||
if(harq_pid >= dlsch0->Mdlharq) {
|
||||
LOG_E(PHY,"illegal harq_pid %d\n", harq_pid);
|
||||
return(-1);
|
||||
}
|
||||
dlsch0_harq = dlsch0->harq_processes[harq_pid];
|
||||
mimo_mode = dlsch0_harq->mimo_mode;
|
||||
mod_order0 = dlsch0_harq->Qm;
|
||||
@@ -2098,6 +2106,10 @@ int dlsch_modulation(PHY_VARS_eNB* phy_vars_eNB,
|
||||
}else if ((dlsch0 == NULL) && (dlsch1 != NULL)){
|
||||
|
||||
harq_pid = dlsch1->harq_ids[frame%2][subframe_offset];
|
||||
if(harq_pid >= dlsch1->Mdlharq) {
|
||||
LOG_E(PHY,"illegal harq_pid %d\n", harq_pid);
|
||||
return(-1);
|
||||
}
|
||||
dlsch1_harq = dlsch1->harq_processes[harq_pid];
|
||||
mimo_mode = dlsch1_harq->mimo_mode;
|
||||
mod_order0 = dlsch1_harq->Qm;
|
||||
|
||||
@@ -1689,7 +1689,7 @@ void release_harq(PHY_VARS_eNB *eNB,int UE_id,int tb,uint16_t frame,uint8_t subf
|
||||
frame_tx = ul_ACK_subframe2_dl_frame(&eNB->frame_parms,frame,subframe,subframe_tx);
|
||||
if (((1<<m)&mask) > 0) {
|
||||
harq_pid = dlsch0->harq_ids[frame_tx%2][subframe_tx];
|
||||
if ((harq_pid>=0) && (harq_pid<10)) {
|
||||
if ((harq_pid>=0) && (harq_pid<dlsch0->Mdlharq)) {
|
||||
dlsch0_harq = dlsch0->harq_processes[harq_pid];
|
||||
dlsch1_harq = dlsch1->harq_processes[harq_pid];
|
||||
AssertFatal(dlsch0_harq!=NULL,"dlsch0_harq is null\n");
|
||||
|
||||
Reference in New Issue
Block a user