MCPcopy Index your code
hub / github.com/DaveGamble/cJSON / cJSON_CreateStringReference

Function cJSON_CreateStringReference

cJSON.c:2533–2543  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2531}
2532
2533CJSON_PUBLIC(cJSON *) cJSON_CreateStringReference(const char *string)
2534{
2535 cJSON *item = cJSON_New_Item(&global_hooks);
2536 if (item != NULL)
2537 {
2538 item->type = cJSON_String | cJSON_IsReference;
2539 item->valuestring = (char*)cast_away_const(string);
2540 }
2541
2542 return item;
2543}
2544
2545CJSON_PUBLIC(cJSON *) cJSON_CreateObjectReference(const cJSON *child)
2546{

Calls 2

cJSON_New_ItemFunction · 0.85
cast_away_constFunction · 0.85

Used in the wild real call sites across dependent graphs

searching dependent graphs…