From 3025caf93214602f993c8312b96d541a151a2290 Mon Sep 17 00:00:00 2001 From: Jakob Borg Date: Wed, 25 Nov 2015 09:18:54 +0100 Subject: [PATCH] Also remove IP per disco server --- cmd/syncthing/usage_report.go | 11 ----------- lib/config/config.go | 10 ---------- 2 files changed, 21 deletions(-) diff --git a/cmd/syncthing/usage_report.go b/cmd/syncthing/usage_report.go index 68746b609..5c27f5fac 100644 --- a/cmd/syncthing/usage_report.go +++ b/cmd/syncthing/usage_report.go @@ -183,8 +183,6 @@ func reportData(cfg *config.Wrapper, m *model.Model) map[string]interface{} { for _, addr := range cfg.Options().GlobalAnnServers { if addr == "default" || addr == "default-v4" || addr == "default-v6" { defaultAnnounceServersDNS++ - } else if stringIn(addr, config.DefaultDiscoveryServersIP) { - defaultAnnounceServersIP++ } else { otherAnnounceServers++ } @@ -220,15 +218,6 @@ func reportData(cfg *config.Wrapper, m *model.Model) map[string]interface{} { return res } -func stringIn(needle string, haystack []string) bool { - for _, s := range haystack { - if needle == s { - return true - } - } - return false -} - type usageReportingService struct { cfg *config.Wrapper model *model.Model diff --git a/lib/config/config.go b/lib/config/config.go index bdeabc21f..43c128f81 100644 --- a/lib/config/config.go +++ b/lib/config/config.go @@ -48,16 +48,6 @@ var ( // DefaultDiscoveryServers should be substituted when the configuration // contains default. DefaultDiscoveryServers = append(DefaultDiscoveryServersV4, DefaultDiscoveryServersV6...) - - // DefaultDiscoveryServersIP is used by the usage reporting. - DefaultDiscoveryServersIP = []string{ - "https://194.126.249.5/?id=SR7AARM-TCBUZ5O-VFAXY4D-CECGSDE-3Q6IZ4G-XG7AH75-OBIXJQV-QJ6NLQA", - "https://45.55.230.38/?id=AQEHEO2-XOS7QRA-X2COH5K-PO6OPVA-EWOSEGO-KZFMD32-XJ4ZV46-CUUVKAS", - "https://128.199.95.124/?id=VK6HNJ3-VVMM66S-HRVWSCR-IXEHL2H-U4AQ4MW-UCPQBWX-J2L2UBK-NVZRDQZ", - "https://[2001:470:28:4d6::5]/?id=SR7AARM-TCBUZ5O-VFAXY4D-CECGSDE-3Q6IZ4G-XG7AH75-OBIXJQV-QJ6NLQA", - "https://[2604:a880:800:10::182:a001]/?id=AQEHEO2-XOS7QRA-X2COH5K-PO6OPVA-EWOSEGO-KZFMD32-XJ4ZV46-CUUVKAS", - "https://[2400:6180:0:d0::d9:d001]/?id=VK6HNJ3-VVMM66S-HRVWSCR-IXEHL2H-U4AQ4MW-UCPQBWX-J2L2UBK-NVZRDQZ", - } ) func New(myID protocol.DeviceID) Configuration {