config: make sure that anchor-confirms is non-zero.

We don't actually look into mempool, so setting zero is misleading.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell 2016-10-07 14:00:16 +10:30
parent a19762b55c
commit 8c8fa2cecd

View File

@ -233,6 +233,9 @@ static void check_config(struct lightningd_state *dstate)
"Warning: forever-confirms of %u is less than 100!",
dstate->config.forever_confirms);
if (dstate->config.anchor_confirms == 0)
fatal("anchor-confirms must be greater than zero");
/* BOLT #2:
*
* a node MUST estimate the deadline for successful redemption