[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [metrics-lib/master] Don't add non-existent directory to parse history.
commit 3db9e029bbe2b62f4faaf0ada4fa121b12723d7e
Author: Karsten Loesing <karsten.loesing@xxxxxxx>
Date: Thu Aug 20 09:39:49 2015 +0200
Don't add non-existent directory to parse history.
---
src/org/torproject/descriptor/impl/DescriptorReaderImpl.java | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/org/torproject/descriptor/impl/DescriptorReaderImpl.java b/src/org/torproject/descriptor/impl/DescriptorReaderImpl.java
index 5517889..8809d7e 100644
--- a/src/org/torproject/descriptor/impl/DescriptorReaderImpl.java
+++ b/src/org/torproject/descriptor/impl/DescriptorReaderImpl.java
@@ -220,6 +220,9 @@ public class DescriptorReaderImpl implements DescriptorReader {
}
private void readDescriptors() {
for (File directory : this.directories) {
+ if (!directory.exists() || !directory.isDirectory()) {
+ continue;
+ }
Stack<File> files = new Stack<File>();
files.add(directory);
boolean abortReading = false;
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits