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

Function new_channel_subd_

lightningd/subd.c:815–843  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

813}
814
815struct subd *new_channel_subd_(const tal_t *ctx,
816 struct lightningd *ld,
817 const char *name,
818 void *channel,
819 const struct node_id *node_id,
820 struct logger *base_log,
821 bool talks_to_peer,
822 const char *(*msgname)(int msgtype),
823 unsigned int (*msgcb)(struct subd *, const u8 *,
824 const int *fds),
825 void (*errcb)(void *channel,
826 struct peer_fd *peer_fd,
827 const char *desc,
828 const u8 *err_for_them,
829 bool disconnect,
830 bool warning),
831 void (*billboardcb)(void *channel, bool perm,
832 const char *happenings),
833 ...)
834{
835 va_list ap;
836 struct subd *sd;
837
838 va_start(ap, billboardcb);
839 sd = new_subd(ctx, ld, name, channel, node_id, base_log,
840 talks_to_peer, msgname, msgcb, errcb, billboardcb, &ap);
841 va_end(ap);
842 return sd;
843}
844
845void subd_send_msg(struct subd *sd, const u8 *msg_out)
846{

Callers

nothing calls this directly

Calls 1

new_subdFunction · 0.70

Tested by

no test coverage detected