Lines Matching refs:size_t
90 size_t position;
170 void *(CJSON_CDECL *allocate)(size_t size);
172 void *(CJSON_CDECL *reallocate)(void *pointer, size_t size);
177 static void * CJSON_CDECL internal_malloc(size_t size)
185 static void * CJSON_CDECL internal_realloc(void *pointer, size_t size)
202 size_t length = 0;
308 size_t length;
309 size_t offset;
310 size_t depth; /* How deeply nested (in arrays/objects) is the input at the current offset. */
331 size_t i = 0;
418 input_buffer->offset += (size_t)(after_end - number_c_string);
429 size_t i = 0;
495 input_buffer->offset += (size_t)(after_end - number_c_string);
596 size_t length;
597 size_t offset;
598 size_t depth; /* current nesting depth (for formatted printing) */
605 static unsigned char* ensure(printbuffer * const p, size_t needed)
608 size_t newsize = 0;
718 size_t i = 0;
761 output_pointer = ensure(output_buffer, (size_t)length + sizeof(""));
769 for (i = 0; i < ((size_t)length); i++)
781 output_buffer->offset += (size_t)length;
792 size_t i = 0;
831 output_pointer = ensure(output_buffer, (size_t)length + sizeof(""));
839 for (i = 0; i < ((size_t)length); i++)
851 output_buffer->offset += (size_t)length;
861 size_t i = 0;
1031 size_t allocation_length = 0;
1032 size_t skipped_bytes = 0;
1033 while (((size_t)(input_end - input_buffer->content) < input_buffer->length) && (*input_end != '\"'))
1038 if ((size_t)(input_end + 1 - input_buffer->content) >= input_buffer->length)
1048 if (((size_t)(input_end - input_buffer->content) >= input_buffer->length) || (*input_end != '\"'))
1054 allocation_length = (size_t) (input_end - buffer_at_offset(input_buffer)) - skipped_bytes;
1125 input_buffer->offset = (size_t) (input_end - input_buffer->content);
1138 input_buffer->offset = (size_t)(input_pointer - input_buffer->content);
1150 size_t output_length = 0;
1152 size_t escape_characters = 0;
1196 output_length = (size_t)(input_pointer - input) + escape_characters;
1324 size_t buffer_length;
1338 CJSON_PUBLIC(cJSON *) cJSON_ParseWithLengthOpts(const char *value, size_t buffer_length, const char **return_parse_end, cJSON_bool require_null_terminated)
1423 CJSON_PUBLIC(cJSON *) cJSON_ParseWithLength(const char *value, size_t buffer_length)
1432 static const size_t default_buffer_size = 256;
1514 p.buffer = (unsigned char*)global_hooks.allocate((size_t)prebuffer);
1520 p.length = (size_t)prebuffer;
1545 p.length = (size_t)length;
1653 size_t raw_length = 0;
1785 size_t length = 0;
1814 length = (size_t) (output_buffer->format ? 2 : 1);
1965 size_t length = 0;
1974 length = (size_t) (output_buffer->format ? 2 : 1); /* fmt: {\n */
1993 size_t i;
2013 length = (size_t) (output_buffer->format ? 2 : 1);
2034 length = ((size_t)(output_buffer->format ? 1 : 0) + (size_t)(current_item->next ? 1 : 0));
2062 size_t i;
2079 size_t size = 0;
2099 static cJSON* get_array_item(const cJSON *array, size_t index)
2125 return get_array_item(array, (size_t)index);
2492 return cJSON_DetachItemViaPointer(array, get_array_item(array, (size_t)which));
2534 after_inserted = get_array_item(array, (size_t)which);
2615 return cJSON_ReplaceItemViaPointer(array, get_array_item(array, (size_t)which), newitem);
2858 size_t i = 0;
2870 for(i = 0; a && (i < (size_t)count); i++)
2898 size_t i = 0;
2910 for(i = 0; a && (i < (size_t)count); i++)
2938 size_t i = 0;
2950 for(i = 0; a && (i < (size_t)count); i++)
2978 size_t i = 0;
2990 for (i = 0; a && (i < (size_t)count); i++)
3456 CJSON_PUBLIC(void *) cJSON_malloc(size_t size)