Commit 56b1d24f authored by yaojie's avatar yaojie

fix error InitialContextSetupResponse

parent 7bef73bf
...@@ -882,11 +882,11 @@ int ngap_gNB_handle_initial_context_request(uint32_t assoc_id, ...@@ -882,11 +882,11 @@ int ngap_gNB_handle_initial_context_request(uint32_t assoc_id,
} }
/* Initial context request = UE-related procedure -> stream != 0 */ /* Initial context request = UE-related procedure -> stream != 0 */
if (stream == 0) { //if (stream == 0) {
NGAP_ERROR("[SCTP %d] Received UE-related procedure on stream (%d)\n", // NGAP_ERROR("[SCTP %d] Received UE-related procedure on stream (%d)\n",
assoc_id, stream); // assoc_id, stream);
return -1; // return -1;
} //}
ue_desc_p->rx_stream = stream; ue_desc_p->rx_stream = stream;
ue_desc_p->amf_ue_ngap_id = amf_ue_ngap_id; ue_desc_p->amf_ue_ngap_id = amf_ue_ngap_id;
......
...@@ -710,6 +710,7 @@ int ngap_gNB_initial_ctxt_resp( ...@@ -710,6 +710,7 @@ int ngap_gNB_initial_ctxt_resp(
ie->criticality = NGAP_Criticality_ignore; ie->criticality = NGAP_Criticality_ignore;
ie->value.present = NGAP_InitialContextSetupResponseIEs__value_PR_PDUSessionResourceSetupListCxtRes; ie->value.present = NGAP_InitialContextSetupResponseIEs__value_PR_PDUSessionResourceSetupListCxtRes;
if (initial_ctxt_resp_p->nb_of_pdusessions){
for (i = 0; i < initial_ctxt_resp_p->nb_of_pdusessions; i++) { for (i = 0; i < initial_ctxt_resp_p->nb_of_pdusessions; i++) {
NGAP_PDUSessionResourceSetupItemCxtRes_t *item; NGAP_PDUSessionResourceSetupItemCxtRes_t *item;
NGAP_PDUSessionResourceSetupResponseTransfer_t *pdusessionTransfer_p = NULL; NGAP_PDUSessionResourceSetupResponseTransfer_t *pdusessionTransfer_p = NULL;
...@@ -770,7 +771,7 @@ int ngap_gNB_initial_ctxt_resp( ...@@ -770,7 +771,7 @@ int ngap_gNB_initial_ctxt_resp(
} }
ASN_SEQUENCE_ADD(&out->protocolIEs.list, ie); ASN_SEQUENCE_ADD(&out->protocolIEs.list, ie);
}
/* optional */ /* optional */
if (initial_ctxt_resp_p->nb_of_pdusessions_failed) { if (initial_ctxt_resp_p->nb_of_pdusessions_failed) {
ie = (NGAP_InitialContextSetupResponseIEs_t *)calloc(1, sizeof(NGAP_InitialContextSetupResponseIEs_t)); ie = (NGAP_InitialContextSetupResponseIEs_t *)calloc(1, sizeof(NGAP_InitialContextSetupResponseIEs_t));
......
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