If we get a disconnecting warning or error during a splice command, let * the user know out of an abundance of politeness. * After, we forward the event onto the standard `channel_errmsg`. */
| 1757 | * the user know out of an abundance of politeness. |
| 1758 | * After, we forward the event onto the standard `channel_errmsg`. */ |
| 1759 | static void channel_control_errmsg(struct channel *channel, |
| 1760 | struct peer_fd *peer_fd, |
| 1761 | const char *desc, |
| 1762 | const u8 *err_for_them, |
| 1763 | bool disconnect, |
| 1764 | bool warning) |
| 1765 | { |
| 1766 | struct lightningd *ld = channel->peer->ld; |
| 1767 | struct splice_command *cc = splice_command_for_chan(ld, channel); |
| 1768 | if (cc && disconnect) { |
| 1769 | was_pending(command_fail(cc->cmd, SPLICE_CHANNEL_ERROR, |
| 1770 | "Splice command failed:" |
| 1771 | " %s", desc)); |
| 1772 | } |
| 1773 | |
| 1774 | channel_errmsg(channel, peer_fd, desc, err_for_them, disconnect, warning); |
| 1775 | } |
| 1776 | |
| 1777 | bool peer_start_channeld(struct channel *channel, |
| 1778 | struct peer_fd *peer_fd, |
nothing calls this directly
no test coverage detected