mirror of
https://github.com/aljazceru/lightning.git
synced 2025-12-22 00:24:19 +01:00
getroute: add a risk factor.
We need some way to reflect the tradeoff between the possible delay if a payment gets stuck, and the fees charged by nodes. This adds a risk factor which reflects the probability that a node goes down, and the cost associated with losing access to our funds for a given time. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -29,6 +29,9 @@ bool json_tok_number(const char *buffer, const jsmntok_t *tok,
|
||||
bool json_tok_u64(const char *buffer, const jsmntok_t *tok,
|
||||
uint64_t *num);
|
||||
|
||||
/* Extract double from this (must be a number literal) */
|
||||
bool json_tok_double(const char *buffer, const jsmntok_t *tok, double *num);
|
||||
|
||||
/* Extract satoshis from this (may be a string, or a decimal number literal) */
|
||||
bool json_tok_bitcoin_amount(const char *buffer, const jsmntok_t *tok,
|
||||
uint64_t *satoshi);
|
||||
|
||||
Reference in New Issue
Block a user