aboutsummaryrefslogtreecommitdiff
path: root/src/or/dirauth
diff options
context:
space:
mode:
authorDavid Goulet <dgoulet@torproject.org>2018-05-01 11:25:25 -0400
committerDavid Goulet <dgoulet@torproject.org>2018-05-01 11:45:34 -0400
commit2d79d0155e3bdf42c2b8ff450d4d4bd85ee17c72 (patch)
treef6807a37b26fba453eb0f1db4c484906ebbafb5d /src/or/dirauth
parente504b1b35831e9d18be7b89ab471705b41092606 (diff)
downloadtor-2d79d0155e3bdf42c2b8ff450d4d4bd85ee17c72.tar.gz
tor-2d79d0155e3bdf42c2b8ff450d4d4bd85ee17c72.zip
vote: Move dirvote_recalculate_timing() to voting_schedule.c
By doing so, it is renamed to voting_schedule_recalculate_timing(). This required a lot of changes to include voting_schedule.h everywhere that this function was used. This effectively now makes voting_schedule.{c|h} not include dirauth/dirvote.h for that symbol and thus no dependency on the dirauth module anymore. Signed-off-by: David Goulet <dgoulet@torproject.org>
Diffstat (limited to 'src/or/dirauth')
-rw-r--r--src/or/dirauth/dirvote.c4
-rw-r--r--src/or/dirauth/dirvote.h1
2 files changed, 2 insertions, 3 deletions
diff --git a/src/or/dirauth/dirvote.c b/src/or/dirauth/dirvote.c
index b67b78cbb9..6b7114b141 100644
--- a/src/or/dirauth/dirvote.c
+++ b/src/or/dirauth/dirvote.c
@@ -2768,7 +2768,7 @@ dirvote_act(const or_options_t *options, time_t now)
"Mine is %s.",
keys, hex_str(c->cache_info.identity_digest, DIGEST_LEN));
tor_free(keys);
- dirvote_recalculate_timing(options, now);
+ voting_schedule_recalculate_timing(options, now);
}
#define IF_TIME_FOR_NEXT_ACTION(when_field, done_field) \
@@ -2814,7 +2814,7 @@ dirvote_act(const or_options_t *options, time_t now)
networkstatus_get_latest_consensus_by_flavor(FLAV_NS));
/* XXXX We will want to try again later if we haven't got enough
* signatures yet. Implement this if it turns out to ever happen. */
- dirvote_recalculate_timing(options, now);
+ voting_schedule_recalculate_timing(options, now);
return voting_schedule.voting_starts;
} ENDIF
diff --git a/src/or/dirauth/dirvote.h b/src/or/dirauth/dirvote.h
index 7294962925..228121268f 100644
--- a/src/or/dirauth/dirvote.h
+++ b/src/or/dirauth/dirvote.h
@@ -178,7 +178,6 @@ dirvote_add_signatures(const char *detached_signatures_body, const char *source,
#endif /* HAVE_MODULE_DIRAUTH */
-void dirvote_recalculate_timing(const or_options_t *options, time_t now);
/* Item access */
MOCK_DECL(const char*, dirvote_get_pending_consensus,
(consensus_flavor_t flav));