X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=src%2Futil%2Fevents.rs;h=fd801e4111ed6f3c6b58dcea72f0c7ff1534b116;hb=12a55ae6fc0358808cd7ffaa64e498823f0b2f0c;hp=c2c3ab6a1a71c0ce813dce3eb500e5a94fe53977;hpb=7b4f382e26368be7f010a081e553803b98eb9550;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 {