MCPcopy Create free account
hub / github.com/antirez/botlib / cJSON_ReplaceItemInArray

Function cJSON_ReplaceItemInArray

cJSON.c:2337–2345  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2335}
2336
2337CJSON_PUBLIC(cJSON_bool) cJSON_ReplaceItemInArray(cJSON *array, int which, cJSON *newitem)
2338{
2339 if (which < 0)
2340 {
2341 return false;
2342 }
2343
2344 return cJSON_ReplaceItemViaPointer(array, get_array_item(array, (size_t)which), newitem);
2345}
2346
2347static cJSON_bool replace_item_in_object(cJSON *object, const char *string, cJSON *replacement, cJSON_bool case_sensitive)
2348{

Callers

nothing calls this directly

Calls 2

get_array_itemFunction · 0.85

Tested by

no test coverage detected