mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-19 15:14:23 +01:00
chaintopology: track three different feerates.
Depending on what we're doing, we can want different ones. So use IMMEDIATE (estimatesmartfee 2 CONSERVATIVE), NORMAL (estimatesmartfee 4 ECONOMICAL) and SLOW (estimatesmartfee 100 ECONOMICAL). If one isn't available, we try making each one half the previous. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Christian Decker
parent
ef4d54df94
commit
7151c65535
@@ -55,18 +55,20 @@ struct bitcoind *new_bitcoind(const tal_t *ctx,
|
||||
|
||||
void wait_for_bitcoind(struct bitcoind *bitcoind);
|
||||
|
||||
void bitcoind_estimate_fee_(struct bitcoind *bitcoind,
|
||||
void (*cb)(struct bitcoind *bitcoind,
|
||||
u64 satoshi_per_kw, void *),
|
||||
void *arg);
|
||||
void bitcoind_estimate_fees_(struct bitcoind *bitcoind,
|
||||
const u32 blocks[], const char *estmode[],
|
||||
size_t num_estimates,
|
||||
void (*cb)(struct bitcoind *bitcoind,
|
||||
const u64 satoshi_per_kw[], void *),
|
||||
void *arg);
|
||||
|
||||
#define bitcoind_estimate_fee(bitcoind_, cb, arg) \
|
||||
bitcoind_estimate_fee_((bitcoind_), \
|
||||
typesafe_cb_preargs(void, void *, \
|
||||
(cb), (arg), \
|
||||
struct bitcoind *, \
|
||||
u64), \
|
||||
(arg))
|
||||
#define bitcoind_estimate_fees(bitcoind_, blocks, estmode, num, cb, arg) \
|
||||
bitcoind_estimate_fees_((bitcoind_), (blocks), (estmode), (num), \
|
||||
typesafe_cb_preargs(void, void *, \
|
||||
(cb), (arg), \
|
||||
struct bitcoind *, \
|
||||
const u64 *), \
|
||||
(arg))
|
||||
|
||||
void bitcoind_sendrawtx_(struct bitcoind *bitcoind,
|
||||
const char *hextx,
|
||||
|
||||
Reference in New Issue
Block a user