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

Function payment_mod_get_data

plugins/libplugin-pay.c:2456–2467  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2454}
2455
2456void *payment_mod_get_data(const struct payment *p,
2457 const struct payment_modifier *mod)
2458{
2459 for (size_t i = 0; p->modifiers[i] != NULL; i++)
2460 if (p->modifiers[i] == mod)
2461 return p->modifier_data[i];
2462
2463 /* If we ever get here it means that we asked for the data for a
2464 * non-existent modifier. This is a compile-time/wiring issue, so we
2465 * better check that modifiers match the data we ask for. */
2466 abort();
2467}
2468
2469static struct retry_mod_data *retry_data_init(struct payment *p);
2470

Callers

nothing calls this directly

Calls 1

abortFunction · 0.85

Tested by

no test coverage detected