From: David Goulet Date: Wed, 25 Apr 2018 14:00:17 +0000 (-0400) Subject: dirvote: Rename voter_get_sig_by_algorithm() X-Git-Tag: tor-0.3.4.1-alpha~95^2~10 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=43bee06dd090b5e221a0622389e18a21c0d1e153;p=thirdparty%2Ftor.git dirvote: Rename voter_get_sig_by_algorithm() In order to follow the public namespace of dirvote. Signed-off-by: David Goulet --- diff --git a/src/or/dirauth/dirvote.c b/src/or/dirauth/dirvote.c index dc35c892e0..5af6d841f8 100644 --- a/src/or/dirauth/dirvote.c +++ b/src/or/dirauth/dirvote.c @@ -2490,7 +2490,7 @@ networkstatus_add_detached_signatures(networkstatus_t *target, continue; } - old_sig = voter_get_sig_by_algorithm(target_voter, sig->alg); + old_sig = dirvote_get_voter_sig_by_alg(target_voter, sig->alg); /* If the target already has a good signature from this voter, then skip * this one. */ diff --git a/src/or/dirvote_common.c b/src/or/dirvote_common.c index caa9138f05..b34f4fe20c 100644 --- a/src/or/dirvote_common.c +++ b/src/or/dirvote_common.c @@ -182,8 +182,8 @@ dirvote_recalculate_timing(const or_options_t *options, time_t now) /** Return the signature made by voter using the algorithm * alg, or NULL if none is found. */ document_signature_t * -voter_get_sig_by_algorithm(const networkstatus_voter_info_t *voter, - digest_algorithm_t alg) +dirvote_get_voter_sig_by_alg(const networkstatus_voter_info_t *voter, + digest_algorithm_t alg) { if (!voter->sigs) return NULL; diff --git a/src/or/dirvote_common.h b/src/or/dirvote_common.h index 91d32aaa84..16621244b8 100644 --- a/src/or/dirvote_common.h +++ b/src/or/dirvote_common.h @@ -58,7 +58,7 @@ time_t dirvote_get_start_of_next_interval(time_t now, int offset); time_t dirvote_get_next_valid_after_time(void); -document_signature_t *voter_get_sig_by_algorithm( +document_signature_t *dirvote_get_voter_sig_by_alg( const networkstatus_voter_info_t *voter, digest_algorithm_t alg); diff --git a/src/or/routerparse.c b/src/or/routerparse.c index b27833c3ed..9769d5ab50 100644 --- a/src/or/routerparse.c +++ b/src/or/routerparse.c @@ -3972,7 +3972,7 @@ networkstatus_parse_vote_from_string(const char *s, const char **eos_out, } } - if (voter_get_sig_by_algorithm(v, sig->alg)) { + if (dirvote_get_voter_sig_by_alg(v, sig->alg)) { /* We already parsed a vote with this algorithm from this voter. Use the first one. */ log_fn(LOG_PROTOCOL_WARN, LD_DIR, "We received a networkstatus "