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

Function getchaininfo

plugins/bcli.c:649–661  ·  view source on GitHub ↗

Get infos about the block chain. * Calls `getblockchaininfo` and returns headers count, blocks count, * the chain id, and whether this is initialblockdownload. */

Source from the content-addressed store, hash-verified

647 * the chain id, and whether this is initialblockdownload.
648 */
649static struct command_result *getchaininfo(struct command *cmd,
650 const char *buf UNUSED,
651 const jsmntok_t *toks UNUSED)
652{
653 if (!param(cmd, buf, toks, NULL))
654 return command_param_failed();
655
656 start_bitcoin_cli(NULL, cmd, process_getblockchaininfo, false,
657 BITCOIND_HIGH_PRIO, NULL,
658 "getblockchaininfo", NULL);
659
660 return command_still_pending(cmd);
661}
662
663/* Mutual recursion. */
664static struct command_result *estimatefees_done(struct bitcoin_cli *bcli);

Callers

nothing calls this directly

Calls 4

start_bitcoin_cliFunction · 0.85
command_param_failedFunction · 0.70
command_still_pendingFunction · 0.70
paramFunction · 0.50

Tested by

no test coverage detected