| 2494 | } |
| 2495 | |
| 2496 | CJSON_PUBLIC(cJSON *) cJSON_CreateRaw(const char *raw) |
| 2497 | { |
| 2498 | cJSON *item = cJSON_New_Item(&global_hooks); |
| 2499 | if(item) |
| 2500 | { |
| 2501 | item->type = cJSON_Raw; |
| 2502 | item->valuestring = (char*)cJSON_strdup((const unsigned char*)raw, &global_hooks); |
| 2503 | if(!item->valuestring) |
| 2504 | { |
| 2505 | cJSON_Delete(item); |
| 2506 | return NULL; |
| 2507 | } |
| 2508 | } |
| 2509 | |
| 2510 | return item; |
| 2511 | } |
| 2512 | |
| 2513 | CJSON_PUBLIC(cJSON *) cJSON_CreateArray(void) |
| 2514 | { |
no test coverage detected