Searched refs:global_hooks (Results 1 – 12 of 12) sorted by relevance
186 static internal_hooks global_hooks = { internal_malloc, internal_free, internal_realloc }; variable214 global_hooks.allocate = malloc; in cJSON_InitHooks()215 global_hooks.deallocate = free; in cJSON_InitHooks()216 global_hooks.reallocate = realloc; in cJSON_InitHooks()220 global_hooks.allocate = malloc; in cJSON_InitHooks()223 global_hooks.allocate = hooks->malloc_fn; in cJSON_InitHooks()226 global_hooks.deallocate = free; in cJSON_InitHooks()229 global_hooks.deallocate = hooks->free_fn; in cJSON_InitHooks()233 global_hooks.reallocate = NULL; in cJSON_InitHooks()234 if ((global_hooks.allocate == malloc) && (global_hooks.deallocate == free)) in cJSON_InitHooks()[all …]
40 parsebuffer.hooks = global_hooks; in assert_print_array()47 formatted_buffer.hooks = global_hooks; in assert_print_array()54 unformatted_buffer.hooks = global_hooks; in assert_print_array()
41 parsebuffer.hooks = global_hooks; in assert_print_object()48 formatted_buffer.hooks = global_hooks; in assert_print_object()55 unformatted_buffer.hooks = global_hooks; in assert_print_object()
51 buffer.hooks = global_hooks; in assert_parse_string()56 global_hooks.deallocate(item->valuestring); in assert_parse_string()65 buffer.hooks = global_hooks; in assert_not_parse_string()
41 buffer.hooks = global_hooks; in assert_print_value()45 parsebuffer.hooks = global_hooks; in assert_print_value()
36 global_hooks.deallocate(item->valuestring); in reset()40 global_hooks.deallocate(item->string); in reset()
58 parsebuffer.hooks = global_hooks; in assert_not_object()70 parsebuffer.hooks = global_hooks; in assert_parse_object()
50 buffer.hooks = global_hooks; in assert_not_array()61 buffer.hooks = global_hooks; in assert_parse_array()
35 buffer.hooks = global_hooks; in assert_print_string()
49 buffer.hooks = global_hooks; in assert_parse_value()
38 buffer.hooks = global_hooks; in assert_print_number()
460 buffer.hooks = global_hooks; in skip_utf8_bom_should_skip_bom()472 buffer.hooks = global_hooks; in skip_utf8_bom_should_not_skip_bom_if_not_at_beginning()569 char *name = (char*)cJSON_strdup((const unsigned char*)"number", &global_hooks); in cjson_add_item_to_object_should_not_use_after_free_when_string_is_aliased()