Browse Source

lib/connections: Fix rate limiting on arm64 (fixes #3921)

Skip-check: metalint

GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3922
Audrius Butkevicius 8 years ago
parent
commit
2c4b92d410
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lib/connections/limiter.go

+ 1 - 1
lib/connections/limiter.go

@@ -65,7 +65,7 @@ func (lim *limiter) CommitConfiguration(from, to config.Configuration) bool {
 		lim.read.SetLimit(1024 * rate.Limit(to.Options.MaxRecvKbps))
 	}
 
-	if to.Options.MaxSendKbps < 0 {
+	if to.Options.MaxSendKbps <= 0 {
 		lim.write.SetLimit(rate.Inf)
 	} else {
 		lim.write.SetLimit(1024 * rate.Limit(to.Options.MaxSendKbps))