[FIX] Забытая проверка в verifyHDir

This commit is contained in:
Gravit 2019-04-27 19:56:55 +07:00
parent 63183873a5
commit b1fe3cf2a9
No known key found for this signature in database
GPG key ID: 061981E1E85D3216

View file

@ -552,7 +552,7 @@ public static void verifyHDir(Path dir, HashedDir hdir, FileNameMatcher matcher,
if(v.getType().equals(HashedEntry.Type.FILE)) isFoundFile.set(true); if(v.getType().equals(HashedEntry.Type.FILE)) isFoundFile.set(true);
LogHelper.error("Mismatch %s", e); LogHelper.error("Mismatch %s", e);
}); });
throw new SecurityException(String.format("Forbidden modification: '%s'", IOHelper.getFileName(dir))); if(isFoundFile.get()) throw new SecurityException(String.format("Forbidden modification: '%s'", IOHelper.getFileName(dir)));
} }
} }