multi: extend lnpeer.Peer interface with Disconnect function
This will be used in the gossiper to disconnect from peers if their ban score passes the ban threshold.
This commit is contained in:
8 files changed
+78
-30
No files matched your search
@@ -684,6 +684,8 @@ func (s *mockServer) RemoteFeatures() *lnwire.FeatureVector {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (s *mockServer) Disconnect(err error) {}
|
||||
|
||||
func (s *mockServer) Stop() error {
|
||||
if !atomic.CompareAndSwapInt32(&s.shutdown, 0, 1) {
|
||||
return nil
|
||||
|
||||
Reference in new issue
Block a user