dual-fund: remove flag for option_anchor_outputs

It's assumed true
This commit is contained in:
niftynei 2020-09-15 20:18:40 -05:00 committed by Rusty Russell
parent 9af6e83393
commit 9c1675fcb9
5 changed files with 7 additions and 16 deletions

View File

@ -1034,9 +1034,6 @@ void peer_start_dualopend(struct peer *peer,
uc->minimum_depth,
feerate_min(peer->ld, NULL),
feerate_max(peer->ld, NULL),
feature_negotiated(peer->ld->our_features,
peer->their_features,
OPT_ANCHOR_OUTPUTS),
send_msg);
subd_send_msg(uc->open_daemon, take(msg));
}

View File

@ -118,7 +118,6 @@ struct state {
struct channel *channel;
struct feature_set *our_features;
bool option_anchor_outputs;
/* Set of pending changes to send to peer */
struct psbt_changeset *changeset;
@ -1121,8 +1120,7 @@ static u8 *accepter_start(struct state *state, const u8 *oc2_msg)
&state->our_points, &state->their_points,
&state->our_funding_pubkey,
&state->their_funding_pubkey,
true,
state->option_anchor_outputs,
true, true,
REMOTE);
local_commit = initial_channel_tx(state, &wscript, state->channel,
@ -1426,7 +1424,6 @@ int main(int argc, char *argv[])
&state->our_funding_pubkey,
&state->minimum_depth,
&state->min_feerate, &state->max_feerate,
&state->option_anchor_outputs,
&inner))
master_badmsg(WIRE_DUAL_OPEN_INIT, msg);

View File

@ -26,7 +26,6 @@ msgdata,dual_open_init,our_funding_pubkey,pubkey,
msgdata,dual_open_init,minimum_depth,u32,
msgdata,dual_open_init,min_feerate,u32,
msgdata,dual_open_init,max_feerate,u32,
msgdata,dual_open_init,option_anchor_outputs,bool,
# Optional msg to send.
msgdata,dual_open_init,len,u16,
msgdata,dual_open_init,msg,u8,len

Can't render this file because it has a wrong number of fields in line 11.

View File

@ -57,7 +57,7 @@ bool dualopend_wire_is_defined(u16 type)
/* WIRE: DUAL_OPEN_INIT */
u8 *towire_dual_open_init(const tal_t *ctx, const struct chainparams *chainparams, const struct feature_set *our_feature_set, const u8 *their_init_features, const struct channel_config *our_config, u32 max_to_self_delay, struct amount_msat min_effective_htlc_capacity_msat, const struct per_peer_state *pps, const struct basepoints *our_basepoints, const struct pubkey *our_funding_pubkey, u32 minimum_depth, u32 min_feerate, u32 max_feerate, bool option_anchor_outputs, const u8 *msg)
u8 *towire_dual_open_init(const tal_t *ctx, const struct chainparams *chainparams, const struct feature_set *our_feature_set, const u8 *their_init_features, const struct channel_config *our_config, u32 max_to_self_delay, struct amount_msat min_effective_htlc_capacity_msat, const struct per_peer_state *pps, const struct basepoints *our_basepoints, const struct pubkey *our_funding_pubkey, u32 minimum_depth, u32 min_feerate, u32 max_feerate, const u8 *msg)
{
u16 their_init_features_len = tal_count(their_init_features);
u16 len = tal_count(msg);
@ -81,14 +81,13 @@ u8 *towire_dual_open_init(const tal_t *ctx, const struct chainparams *chainparam
towire_u32(&p, minimum_depth);
towire_u32(&p, min_feerate);
towire_u32(&p, max_feerate);
towire_bool(&p, option_anchor_outputs);
/* Optional msg to send. */
towire_u16(&p, len);
towire_u8_array(&p, msg, len);
return memcheck(p, tal_count(p));
}
bool fromwire_dual_open_init(const tal_t *ctx, const void *p, const struct chainparams **chainparams, struct feature_set **our_feature_set, u8 **their_init_features, struct channel_config *our_config, u32 *max_to_self_delay, struct amount_msat *min_effective_htlc_capacity_msat, struct per_peer_state **pps, struct basepoints *our_basepoints, struct pubkey *our_funding_pubkey, u32 *minimum_depth, u32 *min_feerate, u32 *max_feerate, bool *option_anchor_outputs, u8 **msg)
bool fromwire_dual_open_init(const tal_t *ctx, const void *p, const struct chainparams **chainparams, struct feature_set **our_feature_set, u8 **their_init_features, struct channel_config *our_config, u32 *max_to_self_delay, struct amount_msat *min_effective_htlc_capacity_msat, struct per_peer_state **pps, struct basepoints *our_basepoints, struct pubkey *our_funding_pubkey, u32 *minimum_depth, u32 *min_feerate, u32 *max_feerate, u8 **msg)
{
u16 their_init_features_len;
u16 len;
@ -117,7 +116,6 @@ bool fromwire_dual_open_init(const tal_t *ctx, const void *p, const struct chain
*minimum_depth = fromwire_u32(&cursor, &plen);
*min_feerate = fromwire_u32(&cursor, &plen);
*max_feerate = fromwire_u32(&cursor, &plen);
*option_anchor_outputs = fromwire_bool(&cursor, &plen);
/* Optional msg to send. */
len = fromwire_u16(&cursor, &plen);
// 2nd case msg
@ -415,4 +413,4 @@ bool fromwire_dual_open_dev_memleak_reply(const void *p, bool *leak)
*leak = fromwire_bool(&cursor, &plen);
return cursor != NULL;
}
// SHA256STAMP:05607d3abf4cb9831ce6e8a2be24cb6e446a949cd8e5fe69620556a2dbbdb772
// SHA256STAMP:45ac65939acab987dfb71715f3a03db62863aa2048923666845e2adf45387eba

View File

@ -51,8 +51,8 @@ bool dualopend_wire_is_defined(u16 type);
/* WIRE: DUAL_OPEN_INIT */
u8 *towire_dual_open_init(const tal_t *ctx, const struct chainparams *chainparams, const struct feature_set *our_feature_set, const u8 *their_init_features, const struct channel_config *our_config, u32 max_to_self_delay, struct amount_msat min_effective_htlc_capacity_msat, const struct per_peer_state *pps, const struct basepoints *our_basepoints, const struct pubkey *our_funding_pubkey, u32 minimum_depth, u32 min_feerate, u32 max_feerate, bool option_anchor_outputs, const u8 *msg);
bool fromwire_dual_open_init(const tal_t *ctx, const void *p, const struct chainparams **chainparams, struct feature_set **our_feature_set, u8 **their_init_features, struct channel_config *our_config, u32 *max_to_self_delay, struct amount_msat *min_effective_htlc_capacity_msat, struct per_peer_state **pps, struct basepoints *our_basepoints, struct pubkey *our_funding_pubkey, u32 *minimum_depth, u32 *min_feerate, u32 *max_feerate, bool *option_anchor_outputs, u8 **msg);
u8 *towire_dual_open_init(const tal_t *ctx, const struct chainparams *chainparams, const struct feature_set *our_feature_set, const u8 *their_init_features, const struct channel_config *our_config, u32 max_to_self_delay, struct amount_msat min_effective_htlc_capacity_msat, const struct per_peer_state *pps, const struct basepoints *our_basepoints, const struct pubkey *our_funding_pubkey, u32 minimum_depth, u32 min_feerate, u32 max_feerate, const u8 *msg);
bool fromwire_dual_open_init(const tal_t *ctx, const void *p, const struct chainparams **chainparams, struct feature_set **our_feature_set, u8 **their_init_features, struct channel_config *our_config, u32 *max_to_self_delay, struct amount_msat *min_effective_htlc_capacity_msat, struct per_peer_state **pps, struct basepoints *our_basepoints, struct pubkey *our_funding_pubkey, u32 *minimum_depth, u32 *min_feerate, u32 *max_feerate, u8 **msg);
/* WIRE: DUAL_OPEN_GOT_OFFER */
/* dualopend->master: they offered channel */
@ -97,4 +97,4 @@ bool fromwire_dual_open_dev_memleak_reply(const void *p, bool *leak);
#endif /* LIGHTNING_OPENINGD_DUALOPEND_WIREGEN_H */
// SHA256STAMP:05607d3abf4cb9831ce6e8a2be24cb6e446a949cd8e5fe69620556a2dbbdb772
// SHA256STAMP:45ac65939acab987dfb71715f3a03db62863aa2048923666845e2adf45387eba