| 1605 | } |
| 1606 | |
| 1607 | static void |
| 1608 | connect_dest(struct multifundchannel_destination *dest) |
| 1609 | { |
| 1610 | struct multifundchannel_command *mfc = dest->mfc; |
| 1611 | struct command *cmd = mfc->cmd; |
| 1612 | const char *id; |
| 1613 | struct out_req *req; |
| 1614 | |
| 1615 | id = fmt_node_id(tmpctx, &dest->id); |
| 1616 | plugin_log(mfc->cmd->plugin, LOG_DBG, |
| 1617 | "mfc %"PRIu64", dest %u: connect %s.", |
| 1618 | mfc->id, dest->index, id); |
| 1619 | |
| 1620 | req = jsonrpc_request_start(cmd, |
| 1621 | "connect", |
| 1622 | &connect_ok, |
| 1623 | &connect_err, |
| 1624 | dest); |
| 1625 | if (dest->addrhint) |
| 1626 | json_add_string(req->js, "id", |
| 1627 | tal_fmt(tmpctx, "%s@%s", |
| 1628 | id, |
| 1629 | dest->addrhint)); |
| 1630 | else |
| 1631 | json_add_node_id(req->js, "id", &dest->id); |
| 1632 | send_outreq(req); |
| 1633 | } |
| 1634 | |
| 1635 | /*----------------------------------------------------------------------------- |
| 1636 | Starting |
no test coverage detected