MCPcopy Create free account
hub / github.com/Netis/cloud-probe / cJSON_CreateObjectReference

Function cJSON_CreateObjectReference

cpworker/src/cJSON/cJSON.c:2507–2516  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2505}
2506
2507CJSON_PUBLIC(cJSON *) cJSON_CreateObjectReference(const cJSON *child)
2508{
2509 cJSON *item = cJSON_New_Item(&global_hooks);
2510 if (item != NULL) {
2511 item->type = cJSON_Object | cJSON_IsReference;
2512 item->child = (cJSON*)cast_away_const(child);
2513 }
2514
2515 return item;
2516}
2517
2518CJSON_PUBLIC(cJSON *) cJSON_CreateArrayReference(const cJSON *child) {
2519 cJSON *item = cJSON_New_Item(&global_hooks);

Callers

nothing calls this directly

Calls 2

cJSON_New_ItemFunction · 0.85
cast_away_constFunction · 0.85

Tested by

no test coverage detected