diff options
author | Matthias Sohn <matthias.sohn@sap.com> | 2020-11-26 00:24:56 +0100 |
---|---|---|
committer | Matthias Sohn <matthias.sohn@sap.com> | 2020-11-26 01:17:49 +0100 |
commit | 3996408cdefccadaf64ec3e0a4e84c8206ca4f90 (patch) | |
tree | 72cb5e7c8fc0bbe6ca4928256a0a8234d1fd88ef /org.eclipse.jgit/src/org | |
parent | fde7a271a4f961484ae6e8357fd64277cfc03585 (diff) | |
download | jgit-3996408cdefccadaf64ec3e0a4e84c8206ca4f90.tar.gz jgit-3996408cdefccadaf64ec3e0a4e84c8206ca4f90.zip |
GC#deleteOrphans: handle failure to list files in pack directory
- log an error
- either there is no list or it is incomplete hence return immediately
Change-Id: Ieee5378ca06304056b9ccc30c1acd5f52360052d
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
Diffstat (limited to 'org.eclipse.jgit/src/org')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java index 25c5dcf8a5..5bc2052f85 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java @@ -986,8 +986,9 @@ public class GC { // .pack, .keep, .index, .bitmap to avoid look ahead .sorted(Collections.reverseOrder()) .collect(Collectors.toList()); - } catch (IOException e1) { - // ignore + } catch (IOException e) { + LOG.error(e.getMessage(), e); + return; } if (fileNames == null) { return; |