| 3721 | } |
| 3722 | |
| 3723 | static unsigned int dual_opend_msg(struct subd *dualopend, |
| 3724 | const u8 *msg, const int *fds) |
| 3725 | { |
| 3726 | enum dualopend_wire t = fromwire_peektype(msg); |
| 3727 | struct channel *channel = dualopend->channel; |
| 3728 | |
| 3729 | switch (t) { |
| 3730 | case WIRE_DUALOPEND_GOT_OFFER: |
| 3731 | accepter_got_offer(dualopend, dualopend->channel, msg); |
| 3732 | return 0; |
| 3733 | case WIRE_DUALOPEND_GOT_RBF_OFFER: |
| 3734 | rbf_got_offer(dualopend, msg); |
| 3735 | return 0; |
| 3736 | case WIRE_DUALOPEND_PSBT_CHANGED: |
| 3737 | handle_psbt_changed(dualopend, channel, msg); |
| 3738 | return 0; |
| 3739 | case WIRE_DUALOPEND_COMMIT_READY: |
| 3740 | handle_commit_ready(dualopend, channel, msg); |
| 3741 | return 0; |
| 3742 | case WIRE_DUALOPEND_COMMIT_RCVD: |
| 3743 | handle_commit_received(dualopend, channel, msg); |
| 3744 | return 0; |
| 3745 | case WIRE_DUALOPEND_RBF_VALIDATE: |
| 3746 | handle_validate_rbf(dualopend, msg); |
| 3747 | return 0; |
| 3748 | case WIRE_DUALOPEND_VALIDATE_LEASE: |
| 3749 | handle_validate_lease(dualopend, msg); |
| 3750 | return 0; |
| 3751 | case WIRE_DUALOPEND_FUNDING_SIGS: |
| 3752 | handle_peer_tx_sigs_msg(dualopend, msg); |
| 3753 | return 0; |
| 3754 | case WIRE_DUALOPEND_TX_SIGS_SENT: |
| 3755 | handle_peer_tx_sigs_sent(dualopend, fds, msg); |
| 3756 | return 0; |
| 3757 | case WIRE_DUALOPEND_PEER_LOCKED: |
| 3758 | handle_peer_locked(dualopend, msg); |
| 3759 | return 0; |
| 3760 | case WIRE_DUALOPEND_DRY_RUN: |
| 3761 | handle_dry_run_finished(dualopend, msg); |
| 3762 | return 0; |
| 3763 | case WIRE_DUALOPEND_CHANNEL_LOCKED: |
| 3764 | if (tal_count(fds) != 1) |
| 3765 | return 1; |
| 3766 | handle_channel_locked(dualopend, fds, msg); |
| 3767 | return 0; |
| 3768 | case WIRE_DUALOPEND_GOT_SHUTDOWN: |
| 3769 | handle_peer_wants_to_close(dualopend, msg); |
| 3770 | return 0; |
| 3771 | case WIRE_DUALOPEND_SHUTDOWN_COMPLETE: |
| 3772 | if (tal_count(fds) != 1) |
| 3773 | return 1; |
| 3774 | handle_channel_closed(dualopend, fds, msg); |
| 3775 | return 0; |
| 3776 | case WIRE_DUALOPEND_FAIL_FALLEN_BEHIND: |
| 3777 | channel_fail_fallen_behind(dualopend, msg); |
| 3778 | return 0; |
| 3779 | case WIRE_DUALOPEND_VALIDATE_INPUTS: |
| 3780 | handle_validate_inputs(dualopend, msg); |
nothing calls this directly
no test coverage detected