summaryrefslogtreecommitdiff
path: root/src/or/dirvote.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2011-05-15 20:09:10 -0400
committerNick Mathewson <nickm@torproject.org>2011-05-15 20:09:10 -0400
commit4c3853aca8708ecf2d6eb4e2d8fcf8ef5fd68611 (patch)
treed76a05b933fef271e890e27f7933fa4a6668219b /src/or/dirvote.c
parentd29c2eb9214a82653a18d51e643d637851dcd145 (diff)
parent00ff80e0ae3a07ff3e2148d66d59716bc4630096 (diff)
downloadtor-4c3853aca8708ecf2d6eb4e2d8fcf8ef5fd68611.tar.gz
tor-4c3853aca8708ecf2d6eb4e2d8fcf8ef5fd68611.zip
Merge remote-tracking branch 'origin/maint-0.2.1' into maint-0.2.2
Conflicts: src/or/networkstatus.c
Diffstat (limited to 'src/or/dirvote.c')
-rw-r--r--src/or/dirvote.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/or/dirvote.c b/src/or/dirvote.c
index dd156bd9d9..517dac5074 100644
--- a/src/or/dirvote.c
+++ b/src/or/dirvote.c
@@ -397,8 +397,9 @@ compare_vote_rs(const vote_routerstatus_t *a, const vote_routerstatus_t *b)
if ((r = fast_memcmp(a->status.identity_digest, b->status.identity_digest,
DIGEST_LEN)))
return r;
- if ((r = fast_memcmp(a->status.descriptor_digest, b->status.descriptor_digest,
- DIGEST_LEN)))
+ if ((r = fast_memcmp(a->status.descriptor_digest,
+ b->status.descriptor_digest,
+ DIGEST_LEN)))
return r;
if ((r = (int)(b->status.published_on - a->status.published_on)))
return r;
@@ -1705,7 +1706,8 @@ networkstatus_compute_consensus(smartlist_t *votes,
if (index[v_sl_idx] < size[v_sl_idx]) {
rs = smartlist_get(v->routerstatus_list, index[v_sl_idx]);
if (!lowest_id ||
- fast_memcmp(rs->status.identity_digest, lowest_id, DIGEST_LEN) < 0)
+ fast_memcmp(rs->status.identity_digest,
+ lowest_id, DIGEST_LEN) < 0)
lowest_id = rs->status.identity_digest;
}
});
@@ -1769,7 +1771,7 @@ networkstatus_compute_consensus(smartlist_t *votes,
rs = compute_routerstatus_consensus(matching_descs, consensus_method,
microdesc_digest);
/* Copy bits of that into rs_out. */
- tor_assert(fast_memeq(lowest_id, rs->status.identity_digest, DIGEST_LEN));
+ tor_assert(fast_memeq(lowest_id, rs->status.identity_digest,DIGEST_LEN));
memcpy(rs_out.identity_digest, lowest_id, DIGEST_LEN);
memcpy(rs_out.descriptor_digest, rs->status.descriptor_digest,
DIGEST_LEN);