mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-03-03 18:57:06 +01:00
chaintopology: always initialize smoothed feerate if it's the first entry.
Not just during startup: we could have bitcoind not give estimates until later, but we don't want to smooth with zero. The test changes in next patch trigger this, so I didn't write a test with this patch. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
807e62b05d
commit
a75de62477
1 changed files with 1 additions and 1 deletions
|
@ -309,7 +309,7 @@ static void update_feerates(struct bitcoind *bitcoind,
|
|||
continue;
|
||||
|
||||
/* Initial smoothed feerate is the polled feerate */
|
||||
if (topo->feerate_uninitialized) {
|
||||
if (!topo->feerate[i]) {
|
||||
old_feerates[i] = feerate;
|
||||
log_debug(topo->log,
|
||||
"Smoothed feerate estimate for %s initialized to polled estimate %u",
|
||||
|
|
Loading…
Add table
Reference in a new issue