Use talloc for all memory pool (#1263)

This commit is contained in:
Sukchan Lee 2022-01-04 08:29:18 +09:00
parent 49d9ed03c7
commit b988e7edce
768 changed files with 4632 additions and 4901 deletions

View file

@ -25,10 +25,9 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_create(
OpenAPI_binary_t* binary_data_n2_information_ext16
)
{
OpenAPI_inline_object_t *inline_object_local_var = OpenAPI_malloc(sizeof(OpenAPI_inline_object_t));
if (!inline_object_local_var) {
return NULL;
}
OpenAPI_inline_object_t *inline_object_local_var = ogs_malloc(sizeof(OpenAPI_inline_object_t));
ogs_assert(inline_object_local_var);
inline_object_local_var->json_data = json_data;
inline_object_local_var->binary_data_n2_information = binary_data_n2_information;
inline_object_local_var->binary_data_n2_information_ext1 = binary_data_n2_information_ext1;
@ -270,7 +269,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2Information");
OpenAPI_binary_t* decoded_str_binary_data_n2_information = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information);
if (binary_data_n2_information) {
if (!cJSON_IsString(binary_data_n2_information)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information]");
@ -285,7 +285,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext1 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt1");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext1 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext1 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext1);
if (binary_data_n2_information_ext1) {
if (!cJSON_IsString(binary_data_n2_information_ext1)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext1]");
@ -300,7 +301,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext2 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt2");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext2 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext2 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext2);
if (binary_data_n2_information_ext2) {
if (!cJSON_IsString(binary_data_n2_information_ext2)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext2]");
@ -315,7 +317,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext3 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt3");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext3 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext3 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext3);
if (binary_data_n2_information_ext3) {
if (!cJSON_IsString(binary_data_n2_information_ext3)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext3]");
@ -330,7 +333,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext4 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt4");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext4 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext4 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext4);
if (binary_data_n2_information_ext4) {
if (!cJSON_IsString(binary_data_n2_information_ext4)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext4]");
@ -345,7 +349,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext5 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt5");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext5 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext5 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext5);
if (binary_data_n2_information_ext5) {
if (!cJSON_IsString(binary_data_n2_information_ext5)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext5]");
@ -360,7 +365,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext6 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt6");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext6 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext6 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext6);
if (binary_data_n2_information_ext6) {
if (!cJSON_IsString(binary_data_n2_information_ext6)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext6]");
@ -375,7 +381,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext7 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt7");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext7 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext7 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext7);
if (binary_data_n2_information_ext7) {
if (!cJSON_IsString(binary_data_n2_information_ext7)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext7]");
@ -390,7 +397,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext8 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt8");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext8 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext8 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext8);
if (binary_data_n2_information_ext8) {
if (!cJSON_IsString(binary_data_n2_information_ext8)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext8]");
@ -405,7 +413,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext9 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt9");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext9 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext9 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext9);
if (binary_data_n2_information_ext9) {
if (!cJSON_IsString(binary_data_n2_information_ext9)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext9]");
@ -420,7 +429,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext10 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt10");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext10 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext10 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext10);
if (binary_data_n2_information_ext10) {
if (!cJSON_IsString(binary_data_n2_information_ext10)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext10]");
@ -435,7 +445,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext11 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt11");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext11 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext11 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext11);
if (binary_data_n2_information_ext11) {
if (!cJSON_IsString(binary_data_n2_information_ext11)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext11]");
@ -450,7 +461,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext12 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt12");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext12 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext12 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext12);
if (binary_data_n2_information_ext12) {
if (!cJSON_IsString(binary_data_n2_information_ext12)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext12]");
@ -465,7 +477,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext13 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt13");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext13 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext13 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext13);
if (binary_data_n2_information_ext13) {
if (!cJSON_IsString(binary_data_n2_information_ext13)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext13]");
@ -480,7 +493,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext14 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt14");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext14 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext14 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext14);
if (binary_data_n2_information_ext14) {
if (!cJSON_IsString(binary_data_n2_information_ext14)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext14]");
@ -495,7 +509,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext15 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt15");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext15 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext15 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext15);
if (binary_data_n2_information_ext15) {
if (!cJSON_IsString(binary_data_n2_information_ext15)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext15]");
@ -510,7 +525,8 @@ OpenAPI_inline_object_t *OpenAPI_inline_object_parseFromJSON(cJSON *inline_objec
cJSON *binary_data_n2_information_ext16 = cJSON_GetObjectItemCaseSensitive(inline_objectJSON, "binaryDataN2InformationExt16");
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext16 = OpenAPI_malloc(sizeof(OpenAPI_binary_t));
OpenAPI_binary_t* decoded_str_binary_data_n2_information_ext16 = ogs_malloc(sizeof(OpenAPI_binary_t));
ogs_assert(decoded_str_binary_data_n2_information_ext16);
if (binary_data_n2_information_ext16) {
if (!cJSON_IsString(binary_data_n2_information_ext16)) {
ogs_error("OpenAPI_inline_object_parseFromJSON() failed [binary_data_n2_information_ext16]");