From: Dylan William Hardison Date: Fri, 6 Jul 2018 03:40:11 +0000 (-0400) Subject: no bug - use more obvious looping construct X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=57e53a03137969a22cb168bbf02b55c7cedf2f3a;p=thirdparty%2Fbugzilla.git no bug - use more obvious looping construct --- diff --git a/Bugzilla/Memcached.pm b/Bugzilla/Memcached.pm index f3272c194..40755aa29 100644 --- a/Bugzilla/Memcached.pm +++ b/Bugzilla/Memcached.pm @@ -230,9 +230,9 @@ sub should_rate_limit { return 0 unless $name; return 0 unless $memcached; - $tries //= 3; + $tries //= 4; - for my $try (0 .. $tries) { + for my $try (1 .. $tries) { my $now = time; my ($key, @keys) = map { $prefix . ( $now - $_ ) } 0 .. $rate_seconds; $memcached->add($key, 0, $rate_seconds+1);