add lcid check and increase limit to 10

This commit is contained in:
Francisco 2021-01-21 10:19:40 +00:00 committed by Francisco Paisana
parent bed979b722
commit e0937d1dd1
2 changed files with 5 additions and 1 deletions

View File

@ -31,7 +31,7 @@ public:
const static int MAX_SIB_PAYLOAD_LEN = 2048;
const static int MAX_SIBS = 16;
const static int MAX_LC = 10;
const static int MAX_LC = 11;
const static int MAX_LC_GROUP = 4;
const static int MAX_DATA_LIST = 32;
const static int MAX_RAR_LIST = 8;

View File

@ -223,6 +223,10 @@ int bearer_cfg_handler::add_erab(uint8_t
log_h->error("QCI=%d not configured\n", qos.qci);
return SRSLTE_ERROR;
}
if (lcid < 3 or lcid > 10) {
log_h->error("DRB logical channel ids must be within 3 and 10\n");
return SRSLTE_ERROR;
}
erabs[erab_id].id = erab_id;
erabs[erab_id].qos_params = qos;