mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-11 05:33:47 +01:00
Fix pathbias interactions with entry guards
entry_guard_get_by_id_digest() was always returning NULL, which was causing "adventure" and "fun"
This commit is contained in:
parent
783fa2f586
commit
d98b9b6d65
@ -2351,6 +2351,11 @@ entry_guard_get_by_id_digest_for_guard_selection(guard_selection_t *gs,
|
||||
{
|
||||
tor_assert(gs != NULL);
|
||||
|
||||
SMARTLIST_FOREACH(gs->sampled_entry_guards, entry_guard_t *, entry,
|
||||
if (tor_memeq(digest, entry->identity, DIGEST_LEN))
|
||||
return entry;
|
||||
);
|
||||
|
||||
SMARTLIST_FOREACH(gs->chosen_entry_guards, entry_guard_t *, entry,
|
||||
if (tor_memeq(digest, entry->identity, DIGEST_LEN))
|
||||
return entry;
|
||||
|
Loading…
Reference in New Issue
Block a user