Fix NoSuchFileException during directory cleanup in RefDirectory
Bug: 538285
Change-Id: Iab5c381a412cb2c2176af55189668c267ed29fbc
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
(cherry picked from commit 8ab89ef066
)
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
This commit is contained in:
parent
c78d6445ec
commit
667ac8b318
|
@ -1093,7 +1093,7 @@ private static void delete(final File file, final int depth, LockFile rLck)
|
|||
File dir = file.getParentFile();
|
||||
for (int i = 0; i < depth; ++i) {
|
||||
try {
|
||||
Files.delete(dir.toPath());
|
||||
Files.deleteIfExists(dir.toPath());
|
||||
} catch (DirectoryNotEmptyException e) {
|
||||
// Don't log; normal case when there are other refs with the
|
||||
// same prefix
|
||||
|
|
Loading…
Reference in New Issue