| 2501 | } |
| 2502 | |
| 2503 | CJSON_PUBLIC(cJSON *) cJSON_CreateRaw(const char *raw) |
| 2504 | { |
| 2505 | cJSON *item = cJSON_New_Item(&global_hooks); |
| 2506 | if(item) |
| 2507 | { |
| 2508 | item->type = cJSON_Raw; |
| 2509 | item->valuestring = (char*)cJSON_strdup((const unsigned char*)raw, &global_hooks); |
| 2510 | if(!item->valuestring) |
| 2511 | { |
| 2512 | cJSON_Delete(item); |
| 2513 | return NULL; |
| 2514 | } |
| 2515 | } |
| 2516 | |
| 2517 | return item; |
| 2518 | } |
| 2519 | |
| 2520 | CJSON_PUBLIC(cJSON *) cJSON_CreateArray(void) |
| 2521 | { |
no test coverage detected