[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [metrics-tasks/master] Tweak server descriptor verifier (#2768).
commit ed7759ff1afaa926b0823bd94c80330ede4e8f12
Author: Karsten Loesing <karsten.loesing@xxxxxxx>
Date: Tue Apr 17 18:23:49 2012 +0200
Tweak server descriptor verifier (#2768).
Now we learn when a descriptor file could not be parsed due to
non-crypto-related issues, rather than silently ignoring it.
---
task-2768/VerifyServerDescriptors.java | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/task-2768/VerifyServerDescriptors.java b/task-2768/VerifyServerDescriptors.java
index c1cf766..e648d92 100644
--- a/task-2768/VerifyServerDescriptors.java
+++ b/task-2768/VerifyServerDescriptors.java
@@ -52,6 +52,12 @@ public class VerifyServerDescriptors {
int processedDescriptors = 0, verifiedDescriptors = 0;
while (descriptorFiles.hasNext()) {
DescriptorFile descriptorFile = descriptorFiles.next();
+ if (descriptorFile.getException() != null) {
+ System.err.println("Could not read/parse descriptor file "
+ + descriptorFile.getFileName() + ": "
+ + descriptorFile.getException().getMessage());
+ continue;
+ }
if (descriptorFile.getDescriptors() == null) {
continue;
}
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits