]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
clientlog: fix warning reported by static analyzer
authorMiroslav Lichvar <mlichvar@redhat.com>
Mon, 1 Feb 2016 13:37:10 +0000 (14:37 +0100)
committerMiroslav Lichvar <mlichvar@redhat.com>
Mon, 1 Feb 2016 13:37:10 +0000 (14:37 +0100)
clientlog.c

index 3aae7340d046a082889aa7b7d6bd8eec02e15951..74d572ae08d7a041199102ba54d25773d134fa24 100644 (file)
@@ -267,7 +267,7 @@ set_bucket_params(int interval, int burst, uint16_t *max_tokens,
   burst = CLAMP(MIN_LIMIT_BURST, burst, MAX_LIMIT_BURST);
 
   /* Find smallest shift with which the maximum number fits in 16 bits */
-  for (*token_shift = 0; *token_shift <= interval + TS_FRAC; (*token_shift)++) {
+  for (*token_shift = 0; *token_shift < interval + TS_FRAC; (*token_shift)++) {
     if (burst << (TS_FRAC + interval - *token_shift) < 1U << 16)
       break;
   }