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

Function param_raw_invreq

plugins/fetchinvoice.c:1750–1767  ·  view source on GitHub ↗

This version doesn't do sanity checks! */

Source from the content-addressed store, hash-verified

1748
1749/* This version doesn't do sanity checks! */
1750static struct command_result *param_raw_invreq(struct command *cmd,
1751 const char *name,
1752 const char *buffer,
1753 const jsmntok_t *tok,
1754 struct tlv_invoice_request **invreq)
1755{
1756 const char *fail;
1757
1758 *invreq = invrequest_decode(cmd, buffer + tok->start, tok->end - tok->start,
1759 plugin_feature_set(cmd->plugin), chainparams,
1760 &fail);
1761 if (!*invreq)
1762 return command_fail_badparam(cmd, name, buffer, tok,
1763 tal_fmt(cmd,
1764 "Unparsable invreq: %s",
1765 fail));
1766 return NULL;
1767}
1768
1769struct command_result *json_dev_rawrequest(struct command *cmd,
1770 const char *buffer,

Callers

nothing calls this directly

Calls 3

invrequest_decodeFunction · 0.85
plugin_feature_setFunction · 0.70
command_fail_badparamFunction · 0.50

Tested by

no test coverage detected