| 133 | } |
| 134 | |
| 135 | static void dump_htlc(const struct htlc *htlc, const char *prefix) |
| 136 | { |
| 137 | enum htlc_state remote_state; |
| 138 | |
| 139 | if (htlc->state <= RCVD_REMOVE_ACK_REVOCATION) |
| 140 | remote_state = htlc->state + 10; |
| 141 | else |
| 142 | remote_state = htlc->state - 10; |
| 143 | |
| 144 | status_debug("%s: HTLC %s %"PRIu64" = %s/%s %s", |
| 145 | prefix, |
| 146 | htlc_owner(htlc) == LOCAL ? "LOCAL" : "REMOTE", |
| 147 | htlc->id, |
| 148 | htlc_state_name(htlc->state), |
| 149 | htlc_state_name(remote_state), |
| 150 | htlc->r ? "FULFILLED" : htlc->failed ? "FAILED" |
| 151 | : ""); |
| 152 | } |
| 153 | |
| 154 | void dump_htlcs(const struct channel *channel, const char *prefix) |
| 155 | { |
no test coverage detected