mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-04 06:44:24 +01:00
pay: make sure we don't think payment in progress if it immediately fails.
If send_htlc_out() fails, it doesn't initialize pc->out; that can make us think it's still in progress. Reported-by: Jonas Nick Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Christian Decker
parent
bd27eba6f8
commit
477a529856
@@ -252,6 +252,7 @@ static void send_payment(struct command *cmd,
|
||||
pc->ids = tal_steal(pc, ids);
|
||||
pc->msatoshi = route[n_hops-1].amount;
|
||||
pc->path_secrets = tal_steal(pc, path_secrets);
|
||||
pc->out = NULL;
|
||||
|
||||
log_info(cmd->ld->log, "Sending %u over %zu hops to deliver %"PRIu64,
|
||||
route[0].amount, n_hops, pc->msatoshi);
|
||||
|
||||
Reference in New Issue
Block a user