Do not set address for self error

This commit is contained in:
Alexander Simmerl
2018-05-21 18:47:14 +02:00
parent 20e9dd0737
commit 91b6d3f18c
+1 -1
View File
@@ -570,7 +570,7 @@ func (sw *Switch) addPeer(pc peerConn) error {
// and add to our addresses to avoid dialing again
sw.addrBook.RemoveAddress(addr)
sw.addrBook.AddOurAddress(addr)
return ErrSwitchConnectToSelf{addr}
return ErrSwitchConnectToSelf{}
}
// Avoid duplicate