MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / cJSON_GetObjectItem

Function cJSON_GetObjectItem

modules/freeswitch/esl/src/esl_json.c:500–500  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

498ESL_DECLARE(int) cJSON_GetArraySize(cJSON *array) {cJSON *c=array->child;int i=0;while(c)i++,c=c->next;return i;}
499ESL_DECLARE(cJSON *)cJSON_GetArrayItem(cJSON *array,int item) {cJSON *c=array->child; while (c && item>0) item--,c=c->next; return c;}
500ESL_DECLARE(cJSON *)cJSON_GetObjectItem(cJSON *object,const char *string) {cJSON *c=object->child; while (c && cJSON_strcasecmp(c->string,string)) c=c->next; return c;}
501
502/* Utility for array list handling. */
503static void suffix_object(cJSON *prev,cJSON *item) {prev->next=item;item->prev=prev;}

Callers 15

parse_mi_requestFunction · 0.50
prepare_mi_responseFunction · 0.50
_get_mi_paramFunction · 0.50
mi_http_write_respFunction · 0.50
mi_xmlrpc_build_pageFunction · 0.50
fs_renew_statsFunction · 0.50
handle_ioFunction · 0.50
w_sip_to_jsonFunction · 0.50
handle_cmd_replyFunction · 0.50
report_captureFunction · 0.50

Calls 1

cJSON_strcasecmpFunction · 0.70

Tested by

no test coverage detected