X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;ds=inline;f=src%2Futil%2Fevents.rs;h=fd801e4111ed6f3c6b58dcea72f0c7ff1534b116;hb=refs%2Fheads%2F2018-07-43-rebased;hp=c2c3ab6a1a71c0ce813dce3eb500e5a94fe53977;hpb=83e3d67b7925d279c60839749e6088e00b41d7f8;p=rust-lightning diff --git a/src/util/events.rs b/src/util/events.rs index c2c3ab6a..fd801e41 100644 --- a/src/util/events.rs +++ b/src/util/events.rs @@ -104,6 +104,13 @@ pub enum Event { BroadcastChannelUpdate { msg: msgs::ChannelUpdate, }, + + // Events indicating the network loop should change the state of connection with peer: + /// Disconnect the given peer, possibly making an attempt to send an ErrorMessage first. + DisconnectPeer { + node_id: PublicKey, + msg: Option, + } } pub trait EventsProvider {