diff --git a/lightningd/lightningd.c b/lightningd/lightningd.c index 156de206a..2aa02f351 100644 --- a/lightningd/lightningd.c +++ b/lightningd/lightningd.c @@ -797,8 +797,11 @@ int main(int argc, char *argv[]) /*~ Process any HTLCs we were in the middle of when we exited, now * that plugins (who might want to know via htlc_accepted hook) are - * active. */ + * active. These will immediately fail, since no peers are connected, + * however partial payments may still be absorbed into htlc_set. */ + db_begin_transaction(ld->wallet->db); htlcs_resubmit(ld, unconnected_htlcs_in); + db_commit_transaction(ld->wallet->db); /*~ Activate connect daemon. Needs to be after the initialization of * chaintopology, otherwise peers may connect and ask for