From d4e19e516325e211cedb070a487453ad2d1043be Mon Sep 17 00:00:00 2001 From: René Scharfe Date: Sun, 6 Jan 2019 17:45:39 +0100 Subject: object-store: factor out odb_clear_loose_cache() Add and use a function for emptying the loose object cache, so callers don't have to know any of its implementation details. Signed-off-by: Rene Scharfe Signed-off-by: Junio C Hamano --- object-store.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'object-store.h') diff --git a/object-store.h b/object-store.h index 7236c571c0..709bf856b6 100644 --- a/object-store.h +++ b/object-store.h @@ -61,6 +61,9 @@ void odb_load_loose_cache(struct object_directory *odb, int subdir_nr); struct oid_array *odb_loose_cache(struct object_directory *odb, const struct object_id *oid); +/* Empty the loose object cache for the specified object directory. */ +void odb_clear_loose_cache(struct object_directory *odb); + struct packed_git { struct packed_git *next; struct list_head mru; -- cgit v1.3-5-g9baa