From c281165b48d9901d391c583b6d7c28d37edb4ff5 Mon Sep 17 00:00:00 2001 From: Javi Fontan Date: Tue, 16 Jan 2018 13:11:57 +0000 Subject: Cache should hold objects the same size as MaxSize Signed-off-by: Javi Fontan --- plumbing/cache/object_lru.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'plumbing') diff --git a/plumbing/cache/object_lru.go b/plumbing/cache/object_lru.go index 9e850b2..0494539 100644 --- a/plumbing/cache/object_lru.go +++ b/plumbing/cache/object_lru.go @@ -51,7 +51,7 @@ func (c *ObjectLRU) Put(obj plumbing.EncodedObject) { objSize := FileSize(obj.Size()) - if objSize >= c.MaxSize { + if objSize > c.MaxSize { return } -- cgit