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

Function init

plugins/bcli.c:931–949  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

929#endif
930
931static const char *init(struct plugin *p, const char *buffer UNUSED,
932 const jsmntok_t *config UNUSED)
933{
934 wait_and_check_bitcoind(p);
935
936 /* Usually we fake up fees in regtest */
937 if (streq(chainparams->network_name, "regtest"))
938 bitcoind->fake_fees = IFDEV(!bitcoind->no_fake_fees, true);
939 else
940 bitcoind->fake_fees = false;
941
942#if DEVELOPER
943 plugin_set_memleak_handler(p, memleak_mark_bitcoind);
944#endif
945 plugin_log(p, LOG_INFORM,
946 "bitcoin-cli initialized and connected to bitcoind.");
947
948 return NULL;
949}
950
951static const struct plugin_command commands[] = {
952 {

Callers

nothing calls this directly

Calls 3

wait_and_check_bitcoindFunction · 0.85
plugin_logFunction · 0.70

Tested by

no test coverage detected