global: thread zero fee option everywhere.

In most cases, it's the same as option_anchor_outputs, but for
fees it's different.  This transformation is the simplest:
pass it as a pair, and test it explicitly.

In future we could rationalize some paths, but this was nice
and mechanical.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2023-06-26 08:48:21 +09:30
parent e1a9e25412
commit af6d7c0779
38 changed files with 404 additions and 184 deletions

View File

@@ -111,7 +111,8 @@ int main(int argc, char *argv[])
argnum++;
fee = commit_tx_base_fee(feerate_per_kw, 0,
option_anchor_outputs);
option_anchor_outputs,
false);
/* BOLT #3:
* If `option_anchors` applies to the commitment
* transaction, also subtract two times the fixed anchor size