mirror of
https://github.com/open5gs/open5gs.git
synced 2026-05-05 07:08:11 +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
|
|
@ -12,10 +12,9 @@ OpenAPI_pfd_content_t *OpenAPI_pfd_content_create(
|
|||
OpenAPI_domain_name_protocol_t *dn_protocol
|
||||
)
|
||||
{
|
||||
OpenAPI_pfd_content_t *pfd_content_local_var = OpenAPI_malloc(sizeof(OpenAPI_pfd_content_t));
|
||||
if (!pfd_content_local_var) {
|
||||
return NULL;
|
||||
}
|
||||
OpenAPI_pfd_content_t *pfd_content_local_var = ogs_malloc(sizeof(OpenAPI_pfd_content_t));
|
||||
ogs_assert(pfd_content_local_var);
|
||||
|
||||
pfd_content_local_var->pfd_id = pfd_id;
|
||||
pfd_content_local_var->flow_descriptions = flow_descriptions;
|
||||
pfd_content_local_var->urls = urls;
|
||||
|
|
@ -158,7 +157,7 @@ OpenAPI_pfd_content_t *OpenAPI_pfd_content_parseFromJSON(cJSON *pfd_contentJSON)
|
|||
ogs_error("OpenAPI_pfd_content_parseFromJSON() failed [flow_descriptions]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_list_add(flow_descriptionsList , ogs_strdup_or_assert(flow_descriptions_local->valuestring));
|
||||
OpenAPI_list_add(flow_descriptionsList , ogs_strdup(flow_descriptions_local->valuestring));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +177,7 @@ OpenAPI_pfd_content_t *OpenAPI_pfd_content_parseFromJSON(cJSON *pfd_contentJSON)
|
|||
ogs_error("OpenAPI_pfd_content_parseFromJSON() failed [urls]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_list_add(urlsList , ogs_strdup_or_assert(urls_local->valuestring));
|
||||
OpenAPI_list_add(urlsList , ogs_strdup(urls_local->valuestring));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -198,7 +197,7 @@ OpenAPI_pfd_content_t *OpenAPI_pfd_content_parseFromJSON(cJSON *pfd_contentJSON)
|
|||
ogs_error("OpenAPI_pfd_content_parseFromJSON() failed [domain_names]");
|
||||
goto end;
|
||||
}
|
||||
OpenAPI_list_add(domain_namesList , ogs_strdup_or_assert(domain_names_local->valuestring));
|
||||
OpenAPI_list_add(domain_namesList , ogs_strdup(domain_names_local->valuestring));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -210,7 +209,7 @@ OpenAPI_pfd_content_t *OpenAPI_pfd_content_parseFromJSON(cJSON *pfd_contentJSON)
|
|||
}
|
||||
|
||||
pfd_content_local_var = OpenAPI_pfd_content_create (
|
||||
pfd_id ? ogs_strdup_or_assert(pfd_id->valuestring) : NULL,
|
||||
pfd_id ? ogs_strdup(pfd_id->valuestring) : NULL,
|
||||
flow_descriptions ? flow_descriptionsList : NULL,
|
||||
urls ? urlsList : NULL,
|
||||
domain_names ? domain_namesList : NULL,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue