From 3910b913bd0ddd587cb92c28a515121e6ec0ea1d Mon Sep 17 00:00:00 2001 From: Fabian Reinartz Date: Tue, 7 Mar 2017 12:01:25 +0100 Subject: [PATCH] Revert interval overlap comparison changes --- db.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/db.go b/db.go index 081178360..0a89bd45f 100644 --- a/db.go +++ b/db.go @@ -569,17 +569,17 @@ func (db *DB) appendable() []*headBlock { } func intervalOverlap(amin, amax, bmin, bmax int64) bool { - if bmin >= amin && bmin < amax { + if bmin >= amin && bmin <= amax { return true } - if amin >= bmin && amin < bmax { + if amin >= bmin && amin <= bmax { return true } return false } func intervalContains(min, max, t int64) bool { - return t >= min && t < max + return t >= min && t <= max } // blocksForInterval returns all blocks within the partition that may contain