*) Bugfix for NullpointerException in deleteOldHTCache

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@1326 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
theli 19 years ago
parent fd9b64290c
commit 7c22afe3de

@ -157,13 +157,15 @@ public final class plasmaHTCache {
private void deleteOldHTCache(File directory) {
String[] list = directory.list();
File object;
for (int i = list.length - 1; i >= 0 ; i--) {
object = new File(directory, list[i]);
if (object.isFile()) {
object.delete();
} else {
deleteOldHTCache(object);
if (list != null) {
File object;
for (int i = list.length - 1; i >= 0 ; i--) {
object = new File(directory, list[i]);
if (object.isFile()) {
object.delete();
} else {
deleteOldHTCache(object);
}
}
}
directory.delete();

Loading…
Cancel
Save