@@ -29,6 +29,7 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/syncthing/syncthing/lib/protocol"
|
"github.com/syncthing/syncthing/lib/protocol"
|
||||||
|
"github.com/syncthing/syncthing/lib/stringutil"
|
||||||
)
|
)
|
||||||
|
|
||||||
// announcement is the format received from and sent to clients
|
// announcement is the format received from and sent to clients
|
||||||
@@ -440,6 +441,9 @@ func fixupAddresses(remote *net.TCPAddr, addresses []string) []string {
|
|||||||
fixed = append(fixed, uri.String())
|
fixed = append(fixed, uri.String())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Remove duplicate addresses
|
||||||
|
fixed = stringutil.UniqueTrimmedStrings(fixed)
|
||||||
|
|
||||||
return fixed
|
return fixed
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user