fix cppcheck error and warning
This commit is contained in:
@@ -1226,7 +1226,7 @@ do_NR_DLInformationTransfer(
|
||||
criticalExtensions.choice.dlInformationTransfer->dedicatedNAS_Message->size = pdu_length;
|
||||
|
||||
encoded = uper_encode_to_new_buffer (&asn_DEF_NR_DL_DCCH_Message, NULL, (void *) &dl_dcch_msg, (void **)buffer);
|
||||
AssertFatal(encoded > 0,"ASN1 message encoding failed (%s, %lu)!\n",
|
||||
AssertFatal(encoded > 0,"ASN1 message encoding failed (%s, %ld)!\n",
|
||||
"DLInformationTransfer", encoded);
|
||||
LOG_D(NR_RRC,"DLInformationTransfer Encoded %zd bytes\n", encoded);
|
||||
return encoded;
|
||||
@@ -1248,7 +1248,7 @@ uint8_t do_NR_ULInformationTransfer(uint8_t **buffer, uint32_t pdu_length, uint8
|
||||
ulInformationTransfer->dedicatedNAS_Message->size = pdu_length;
|
||||
ulInformationTransfer->lateNonCriticalExtension = NULL;
|
||||
encoded = uper_encode_to_new_buffer (&asn_DEF_NR_UL_DCCH_Message, NULL, (void *) &ul_dcch_msg, (void **) buffer);
|
||||
AssertFatal(encoded > 0,"ASN1 message encoding failed (%s, %lu)!\n",
|
||||
AssertFatal(encoded > 0,"ASN1 message encoding failed (%s, %ld)!\n",
|
||||
"ULInformationTransfer",encoded);
|
||||
LOG_D(NR_RRC,"ULInformationTransfer Encoded %zd bytes\n",encoded);
|
||||
|
||||
|
||||
@@ -2206,14 +2206,14 @@ rrc_ue_process_rrcReconfiguration(
|
||||
uint8_t msg_type = 0;
|
||||
if((pdu_buffer + 1) != NULL){
|
||||
if (*(pdu_buffer + 1) > 0 ) {
|
||||
if(pdu_buffer + 9){
|
||||
if((pdu_buffer + 9) != NULL){
|
||||
msg_type = *(pdu_buffer + 9);
|
||||
} else {
|
||||
LOG_W(NR_RRC, "[UE] Received invalid downlink message\n");
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
if(pdu_buffer + 2){
|
||||
if((pdu_buffer + 2) != NULL){
|
||||
msg_type = *(pdu_buffer + 2);
|
||||
} else {
|
||||
LOG_W(NR_RRC, "[UE] Received invalid downlink message\n");
|
||||
@@ -2796,6 +2796,8 @@ nr_rrc_ue_generate_rrcReestablishmentComplete(
|
||||
uint32_t length;
|
||||
uint8_t buffer[100];
|
||||
length = do_RRCReestablishmentComplete(buffer, rrcReestablishment->rrc_TransactionIdentifier);
|
||||
LOG_I(NR_RRC,"[UE %d][RAPROC] Frame %d : Logical Channel UL-DCCH (SRB1), Generating RRCReestablishmentComplete (bytes%d, gNB %d)\n",
|
||||
ctxt_pP->module_id,ctxt_pP->frame, length, gNB_index);
|
||||
#ifdef ITTI_SIM
|
||||
MessageDef *message_p;
|
||||
uint8_t *message_buffer;
|
||||
|
||||
@@ -708,13 +708,13 @@ int ngap_gNB_initial_ctxt_resp(
|
||||
ie->value.present = NGAP_InitialContextSetupResponseIEs__value_PR_RAN_UE_NGAP_ID;
|
||||
ie->value.choice.RAN_UE_NGAP_ID = initial_ctxt_resp_p->gNB_ue_ngap_id;
|
||||
ASN_SEQUENCE_ADD(&out->protocolIEs.list, ie);
|
||||
/* optional */
|
||||
ie = (NGAP_InitialContextSetupResponseIEs_t *)calloc(1, sizeof(NGAP_InitialContextSetupResponseIEs_t));
|
||||
ie->id = NGAP_ProtocolIE_ID_id_PDUSessionResourceSetupListCxtRes;
|
||||
ie->criticality = NGAP_Criticality_ignore;
|
||||
ie->value.present = NGAP_InitialContextSetupResponseIEs__value_PR_PDUSessionResourceSetupListCxtRes;
|
||||
|
||||
/* optional */
|
||||
if (initial_ctxt_resp_p->nb_of_pdusessions){
|
||||
ie = (NGAP_InitialContextSetupResponseIEs_t *)calloc(1, sizeof(NGAP_InitialContextSetupResponseIEs_t));
|
||||
ie->id = NGAP_ProtocolIE_ID_id_PDUSessionResourceSetupListCxtRes;
|
||||
ie->criticality = NGAP_Criticality_ignore;
|
||||
ie->value.present = NGAP_InitialContextSetupResponseIEs__value_PR_PDUSessionResourceSetupListCxtRes;
|
||||
for (i = 0; i < initial_ctxt_resp_p->nb_of_pdusessions; i++) {
|
||||
NGAP_PDUSessionResourceSetupItemCxtRes_t *item;
|
||||
NGAP_PDUSessionResourceSetupResponseTransfer_t *pdusessionTransfer_p = NULL;
|
||||
|
||||
Reference in New Issue
Block a user