]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Comment updates from review.
authorNick Mathewson <nickm@torproject.org>
Wed, 26 Feb 2020 13:16:30 +0000 (08:16 -0500)
committerGeorge Kadianakis <desnacked@riseup.net>
Tue, 3 Mar 2020 12:35:01 +0000 (14:35 +0200)
src/feature/dirauth/voting_schedule.c
src/feature/hs_common/shared_random_client.c

index ddb2c4bb0792796f78eacda85c35745a9d266494..efc4a0b316efde13a72ee111b0907b42859c8f00 100644 (file)
@@ -3,9 +3,8 @@
 
 /**
  * \file voting_schedule.c
- * \brief This file contains functions that are from the directory authority
- *        subsystem related to voting specifically but used by many part of
- *        tor. The full feature is built as part of the dirauth module.
+ * \brief Compute information about our voting schedule as a directory
+ *    authority.
  **/
 
 #include "feature/dirauth/voting_schedule.h"
index 6b291c9344dd2070c2604017067603686fc353da..ece6e101afc74fc01047d94b8229ba1ebf3a0fc5 100644 (file)
@@ -233,8 +233,10 @@ sr_state_get_start_time_of_current_protocol_run(void)
   time_t beginning_of_curr_round;
 
   /* This function is not used for voting purposes, so if we have a live
-     consensus, use its valid-after as the beginning of the current round,
-     otherwise resort to the voting schedule which should always exist. */
+     consensus, use its valid-after as the beginning of the current round.
+     If we have no consensus but we're an authority, use our own
+     schedule. Otherwise, we have a bug somewhere, so we fall back to the
+     default voting interval. */
   networkstatus_t *ns = networkstatus_get_live_consensus(approx_time());
   if (ns) {
     beginning_of_curr_round = ns->valid_after;