lib/connections, lib/model: Additional connection info in logs (fixes #4499)
GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/4665
This commit is contained in:
committed by
Audrius Butkevicius
parent
6e0f64017a
commit
341b9691a7
@@ -28,6 +28,7 @@ type Connection interface {
|
||||
Transport() string
|
||||
RemoteAddr() net.Addr
|
||||
Priority() int
|
||||
String() string
|
||||
}
|
||||
|
||||
// completeConn is the aggregation of an internalConn and the
|
||||
@@ -114,7 +115,7 @@ func (c internalConn) Transport() string {
|
||||
}
|
||||
|
||||
func (c internalConn) String() string {
|
||||
return fmt.Sprintf("%s-%s/%s", c.LocalAddr(), c.RemoteAddr(), c.connType.String())
|
||||
return fmt.Sprintf("%s-%s/%s", c.LocalAddr(), c.RemoteAddr(), c.Type())
|
||||
}
|
||||
|
||||
type dialerFactory interface {
|
||||
|
||||
Reference in New Issue
Block a user