mirror of
https://github.com/open5gs/open5gs.git
synced 2026-05-04 22:30:09 +00:00
Use talloc for all memory pool (#1263)
This commit is contained in:
parent
49d9ed03c7
commit
b988e7edce
768 changed files with 4632 additions and 4901 deletions
|
|
@ -13,10 +13,9 @@ OpenAPI_charging_information_t *OpenAPI_charging_information_create(
|
|||
char *secondary_chf_instance_id
|
||||
)
|
||||
{
|
||||
OpenAPI_charging_information_t *charging_information_local_var = OpenAPI_malloc(sizeof(OpenAPI_charging_information_t));
|
||||
if (!charging_information_local_var) {
|
||||
return NULL;
|
||||
}
|
||||
OpenAPI_charging_information_t *charging_information_local_var = ogs_malloc(sizeof(OpenAPI_charging_information_t));
|
||||
ogs_assert(charging_information_local_var);
|
||||
|
||||
charging_information_local_var->primary_chf_address = primary_chf_address;
|
||||
charging_information_local_var->secondary_chf_address = secondary_chf_address;
|
||||
charging_information_local_var->primary_chf_set_id = primary_chf_set_id;
|
||||
|
|
@ -156,12 +155,12 @@ OpenAPI_charging_information_t *OpenAPI_charging_information_parseFromJSON(cJSON
|
|||
}
|
||||
|
||||
charging_information_local_var = OpenAPI_charging_information_create (
|
||||
ogs_strdup_or_assert(primary_chf_address->valuestring),
|
||||
ogs_strdup_or_assert(secondary_chf_address->valuestring),
|
||||
primary_chf_set_id ? ogs_strdup_or_assert(primary_chf_set_id->valuestring) : NULL,
|
||||
primary_chf_instance_id ? ogs_strdup_or_assert(primary_chf_instance_id->valuestring) : NULL,
|
||||
secondary_chf_set_id ? ogs_strdup_or_assert(secondary_chf_set_id->valuestring) : NULL,
|
||||
secondary_chf_instance_id ? ogs_strdup_or_assert(secondary_chf_instance_id->valuestring) : NULL
|
||||
ogs_strdup(primary_chf_address->valuestring),
|
||||
ogs_strdup(secondary_chf_address->valuestring),
|
||||
primary_chf_set_id ? ogs_strdup(primary_chf_set_id->valuestring) : NULL,
|
||||
primary_chf_instance_id ? ogs_strdup(primary_chf_instance_id->valuestring) : NULL,
|
||||
secondary_chf_set_id ? ogs_strdup(secondary_chf_set_id->valuestring) : NULL,
|
||||
secondary_chf_instance_id ? ogs_strdup(secondary_chf_instance_id->valuestring) : NULL
|
||||
);
|
||||
|
||||
return charging_information_local_var;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue