[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [tor/master] Improve log when unable to add sigs to pending consensus
commit 75d4bd34976536643b634f860b3d2c0e06d875ee
Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date: Fri Jan 26 14:19:59 2018 -0500
Improve log when unable to add sigs to pending consensus
Closes ticket 24849.
---
changes/ticket24849 | 3 +++
src/or/dirvote.c | 8 +++++++-
2 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/changes/ticket24849 b/changes/ticket24849
new file mode 100644
index 000000000..fd9492acb
--- /dev/null
+++ b/changes/ticket24849
@@ -0,0 +1,3 @@
+ o Minor features (directory authority):
+ - When unable to add signatures to a pending consensus, log the reason
+ why. Closes ticket 24849.
diff --git a/src/or/dirvote.c b/src/or/dirvote.c
index ce82a5ef4..e57f6d46f 100644
--- a/src/or/dirvote.c
+++ b/src/or/dirvote.c
@@ -3551,7 +3551,13 @@ dirvote_add_signatures_to_pending_consensus(
}
r = networkstatus_add_detached_signatures(pc->consensus, sigs,
source, severity, msg_out);
- log_info(LD_DIR,"Added %d signatures to consensus.", r);
+ if (r >= 0) {
+ log_info(LD_DIR,"Added %d signatures to consensus.", r);
+ } else {
+ log_fn(LOG_PROTOCOL_WARN, LD_DIR,
+ "Unable to add signatures to consensus: %s",
+ *msg_out ? *msg_out : "(unknown)");
+ }
if (r >= 1) {
char *new_signatures =
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits