Set invalid inputs error to dlsch_decode

This commit is contained in:
Ismael Gomez 2017-10-29 11:02:18 -07:00
parent be0b832927
commit de937faa20
2 changed files with 5 additions and 2 deletions

View file

@ -610,6 +610,9 @@ static int srslte_pdsch_codeword_decode(srslte_pdsch_t *q, srslte_pdsch_cfg_t *c
} else if (ret == SRSLTE_ERROR) {
*ack = false;
ret = SRSLTE_SUCCESS;
} else if (ret == SRSLTE_ERROR_INVALID_INPUTS) {
*ack = false;
ret = SRSLTE_ERROR;
}
} else {
ERROR("Detected NULL pointer in TB%d &softbuffer=%p &data=%p &ack=%p", codeword_idx, softbuffer, (void*)data, ack);

View file

@ -458,12 +458,12 @@ static int decode_tb(srslte_sch_t *q,
if (cb_segm->F) {
fprintf(stderr, "Error filler bits are not supported. Use standard TBS\n");
return SRSLTE_ERROR;
return SRSLTE_ERROR_INVALID_INPUTS;
}
if (cb_segm->C > softbuffer->max_cb) {
fprintf(stderr, "Error number of CB (%d) exceeds soft buffer size (%d CBs)\n", cb_segm->C, softbuffer->max_cb);
return SRSLTE_ERROR;
return SRSLTE_ERROR_INVALID_INPUTS;
}
bool crc_ok = true;