Add pending-HTLC-failure to and unify force_shutdown() handling 2018-07-force-close-handling
authorMatt Corallo <git@bluematt.me>
Sat, 28 Jul 2018 23:15:45 +0000 (19:15 -0400)
committerMatt Corallo <git@bluematt.me>
Sun, 29 Jul 2018 06:23:02 +0000 (02:23 -0400)
commitc7c8a123ba28e189c98f4d04b369a8061bb0f971
tree0d4b552b6e174ad0c95393f918a9177a4ebcfe43
parent5c32e3cb91e98c84d8ac8093229ded2d912d5b10
Add pending-HTLC-failure to and unify force_shutdown() handling

This patch got a bit bigger than I'd intended, but primarily this
unifies force_shutdown() handling so all the callsites at least
look similar. It also fails backwards any HTLCs which were
completely pending (ie hadn't been committed to) and ensures we
broadcast our local commitment transaction. It also adds a
force_close_channel method to ChannelManager to expose
force-closure.
src/ln/channel.rs
src/ln/channelmanager.rs