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

Function json_scanv

common/json_parse.c:469–490  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

467}
468
469const char *json_scanv(const tal_t *ctx,
470 const char *buffer,
471 const jsmntok_t *tok,
472 const char *guide,
473 va_list ap)
474{
475 va_list cpy;
476 const char *orig_guide = guide, *errmsg;
477
478 /* We need this, since &ap doesn't work on some platforms... */
479 va_copy(cpy, ap);
480 errmsg = parse_guide(buffer, tok, &guide, &cpy);
481 va_end(cpy);
482
483 if (errmsg) {
484 return tal_fmt(ctx, "Parsing '%.*s': %s",
485 (int)(guide - orig_guide), orig_guide,
486 errmsg);
487 }
488 assert(guide[0] == '\0');
489 return NULL;
490}
491
492const char *json_scan(const tal_t *ctx,
493 const char *buffer,

Callers 2

json_scanFunction · 0.85
rpc_scan_coreFunction · 0.85

Calls 1

parse_guideFunction · 0.85

Tested by

no test coverage detected