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

Function param_offer

plugins/fetchinvoice.c:478–495  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

476}
477
478static struct command_result *param_offer(struct command *cmd,
479 const char *name,
480 const char *buffer,
481 const jsmntok_t *tok,
482 struct tlv_offer **offer)
483{
484 const char *fail;
485
486 *offer = offer_decode(cmd, buffer + tok->start, tok->end - tok->start,
487 plugin_feature_set(cmd->plugin), chainparams,
488 &fail);
489 if (!*offer)
490 return command_fail_badparam(cmd, name, buffer, tok,
491 tal_fmt(cmd,
492 "Unparsable offer: %s",
493 fail));
494 return NULL;
495}
496
497static struct blinded_path *make_reply_path(const tal_t *ctx,
498 struct plugin *plugin,

Callers

nothing calls this directly

Calls 3

offer_decodeFunction · 0.85
plugin_feature_setFunction · 0.70
command_fail_badparamFunction · 0.50

Tested by

no test coverage detected