| 2073 | } |
| 2074 | |
| 2075 | static void get_anchor_scriptpubkeys(const tal_t *ctx, u8 **anchor) |
| 2076 | { |
| 2077 | if (!option_anchor_outputs && !option_anchors_zero_fee_htlc_tx) { |
| 2078 | anchor[LOCAL] = anchor[REMOTE] = NULL; |
| 2079 | return; |
| 2080 | } |
| 2081 | |
| 2082 | for (enum side side = 0; side < NUM_SIDES; side++) { |
| 2083 | u8 *wscript = bitcoin_wscript_anchor(tmpctx, |
| 2084 | &funding_pubkey[side]); |
| 2085 | anchor[side] = scriptpubkey_p2wsh(ctx, wscript); |
| 2086 | } |
| 2087 | } |
| 2088 | |
| 2089 | static u8 *scriptpubkey_to_remote(const tal_t *ctx, |
| 2090 | const struct pubkey *remotekey, |
no test coverage detected