mirror of
https://github.com/open5gs/open5gs.git
synced 2026-05-02 21:30:10 +00:00
[SBI] fix crash when no mandatory item (#1350)
NRF crashed if NFService does not have a versions. Versions are mandatory, we've modified the SBI interface for the safety.
This commit is contained in:
parent
acfcbda8fa
commit
900e888dc1
219 changed files with 2474 additions and 0 deletions
|
|
@ -512,6 +512,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_access_net_charging_identifier_t *an_charg_idsItem = OpenAPI_access_net_charging_identifier_parseFromJSON(an_charg_ids_local_nonprimitive);
|
||||
|
||||
if (!an_charg_idsItem) {
|
||||
ogs_error("No an_charg_idsItem");
|
||||
OpenAPI_list_free(an_charg_idsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(an_charg_idsList, an_charg_idsItem);
|
||||
}
|
||||
}
|
||||
|
|
@ -556,6 +562,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_af_event_notification_t *ev_notifsItem = OpenAPI_af_event_notification_parseFromJSON(ev_notifs_local_nonprimitive);
|
||||
|
||||
if (!ev_notifsItem) {
|
||||
ogs_error("No ev_notifsItem");
|
||||
OpenAPI_list_free(ev_notifsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(ev_notifsList, ev_notifsItem);
|
||||
}
|
||||
|
||||
|
|
@ -578,6 +590,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_resources_allocation_info_t *failed_resourc_alloc_reportsItem = OpenAPI_resources_allocation_info_parseFromJSON(failed_resourc_alloc_reports_local_nonprimitive);
|
||||
|
||||
if (!failed_resourc_alloc_reportsItem) {
|
||||
ogs_error("No failed_resourc_alloc_reportsItem");
|
||||
OpenAPI_list_free(failed_resourc_alloc_reportsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(failed_resourc_alloc_reportsList, failed_resourc_alloc_reportsItem);
|
||||
}
|
||||
}
|
||||
|
|
@ -601,6 +619,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_resources_allocation_info_t *succ_resourc_alloc_reportsItem = OpenAPI_resources_allocation_info_parseFromJSON(succ_resourc_alloc_reports_local_nonprimitive);
|
||||
|
||||
if (!succ_resourc_alloc_reportsItem) {
|
||||
ogs_error("No succ_resourc_alloc_reportsItem");
|
||||
OpenAPI_list_free(succ_resourc_alloc_reportsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(succ_resourc_alloc_reportsList, succ_resourc_alloc_reportsItem);
|
||||
}
|
||||
}
|
||||
|
|
@ -635,6 +659,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_out_of_credit_information_t *out_of_cred_reportsItem = OpenAPI_out_of_credit_information_parseFromJSON(out_of_cred_reports_local_nonprimitive);
|
||||
|
||||
if (!out_of_cred_reportsItem) {
|
||||
ogs_error("No out_of_cred_reportsItem");
|
||||
OpenAPI_list_free(out_of_cred_reportsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(out_of_cred_reportsList, out_of_cred_reportsItem);
|
||||
}
|
||||
}
|
||||
|
|
@ -665,6 +695,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_qos_notification_control_info_t *qnc_reportsItem = OpenAPI_qos_notification_control_info_parseFromJSON(qnc_reports_local_nonprimitive);
|
||||
|
||||
if (!qnc_reportsItem) {
|
||||
ogs_error("No qnc_reportsItem");
|
||||
OpenAPI_list_free(qnc_reportsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(qnc_reportsList, qnc_reportsItem);
|
||||
}
|
||||
}
|
||||
|
|
@ -688,6 +724,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_qos_monitoring_report_t *qos_mon_reportsItem = OpenAPI_qos_monitoring_report_parseFromJSON(qos_mon_reports_local_nonprimitive);
|
||||
|
||||
if (!qos_mon_reportsItem) {
|
||||
ogs_error("No qos_mon_reportsItem");
|
||||
OpenAPI_list_free(qos_mon_reportsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(qos_mon_reportsList, qos_mon_reportsItem);
|
||||
}
|
||||
}
|
||||
|
|
@ -711,6 +753,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_ran_nas_rel_cause_t *ran_nas_rel_causesItem = OpenAPI_ran_nas_rel_cause_parseFromJSON(ran_nas_rel_causes_local_nonprimitive);
|
||||
|
||||
if (!ran_nas_rel_causesItem) {
|
||||
ogs_error("No ran_nas_rel_causesItem");
|
||||
OpenAPI_list_free(ran_nas_rel_causesList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(ran_nas_rel_causesList, ran_nas_rel_causesItem);
|
||||
}
|
||||
}
|
||||
|
|
@ -782,6 +830,12 @@ OpenAPI_events_notification_t *OpenAPI_events_notification_parseFromJSON(cJSON *
|
|||
}
|
||||
OpenAPI_port_management_container_t *tsn_port_man_cont_nwttsItem = OpenAPI_port_management_container_parseFromJSON(tsn_port_man_cont_nwtts_local_nonprimitive);
|
||||
|
||||
if (!tsn_port_man_cont_nwttsItem) {
|
||||
ogs_error("No tsn_port_man_cont_nwttsItem");
|
||||
OpenAPI_list_free(tsn_port_man_cont_nwttsList);
|
||||
goto end;
|
||||
}
|
||||
|
||||
OpenAPI_list_add(tsn_port_man_cont_nwttsList, tsn_port_man_cont_nwttsItem);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue