diff options
author | Han-Wen Nienhuys <hanwen@google.com> | 2020-01-29 19:11:00 +0100 |
---|---|---|
committer | Matthias Sohn <matthias.sohn@sap.com> | 2020-02-11 00:03:09 +0100 |
commit | 8c9f7656c3078a4d4a2986400a9700a9c13b416f (patch) | |
tree | 29580fb9462b3ed633a91452e84dc6513e7d86da /org.eclipse.jgit | |
parent | dd203f03c2ac8444b6c4804653c829a986660973 (diff) | |
download | jgit-8c9f7656c3078a4d4a2986400a9700a9c13b416f.tar.gz jgit-8c9f7656c3078a4d4a2986400a9700a9c13b416f.zip |
reftable: clear cache on full compaction
The merged table contains handles to open files. A full compaction
causes those files to be closed, and so further lookups would fail
with EBADF.
Change-Id: I7bb74f7228ecc7fec9535b00e56a617a9c18e00e
Signed-off-by: Han-Wen Nienhuys <hanwen@google.com>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileReftableDatabase.java | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileReftableDatabase.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileReftableDatabase.java index fd80ad9ec0..c9ee165a38 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileReftableDatabase.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/FileReftableDatabase.java @@ -139,6 +139,7 @@ public class FileReftableDatabase extends RefDatabase { reftableDatabase.getLock().lock(); try { reftableStack.compactFully(); + reftableDatabase.clearCache(); } finally { reftableDatabase.getLock().unlock(); } |