MCPcopy Create free account
hub / github.com/ElementsProject/lightning / json_get_id

Function json_get_id

common/json_parse_simple.c:190–197  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

188}
189
190const char *json_get_id(const tal_t *ctx,
191 const char *buffer, const jsmntok_t *obj)
192{
193 const jsmntok_t *idtok = json_get_member(buffer, obj, "id");
194 if (!idtok)
195 return NULL;
196 return json_strdup(ctx, buffer, idtok);
197}
198
199/*-----------------------------------------------------------------------------
200JSMN Result Validation Starts

Callers

nothing calls this directly

Calls 2

json_get_memberFunction · 0.70
json_strdupFunction · 0.70

Tested by

no test coverage detected