diff options
author | Nick Mathewson <nickm@torproject.org> | 2016-11-23 15:33:02 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2016-12-16 11:06:16 -0500 |
commit | bce0f79252e12a791c50e9b11ceb5867eeb07559 (patch) | |
tree | 32dcfbdc51681caf815245ca7d0b13b3015acd5e /src | |
parent | 9cad2628dd8c22d41f0e3c47bcd4c926e733f4c3 (diff) | |
download | tor-bce0f79252e12a791c50e9b11ceb5867eeb07559.tar.gz tor-bce0f79252e12a791c50e9b11ceb5867eeb07559.zip |
Mark some more BUG lines as unreachable.
Diffstat (limited to 'src')
-rw-r--r-- | src/or/entrynodes.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/or/entrynodes.c b/src/or/entrynodes.c index cf35b02ce0..1501bf7f3e 100644 --- a/src/or/entrynodes.c +++ b/src/or/entrynodes.c @@ -539,7 +539,9 @@ remove_guard_from_confirmed_and_primary_lists(guard_selection_t *gs, found_guard = smartlist_get(gs->confirmed_entry_guards, guard->confirmed_idx); if (BUG(guard != found_guard)) { + // LCOV_EXCL_START smartlist_remove_keeporder(gs->confirmed_entry_guards, guard); + // LCOV_EXCL_STOP } else { smartlist_del_keeporder(gs->confirmed_entry_guards, guard->confirmed_idx); @@ -548,7 +550,9 @@ remove_guard_from_confirmed_and_primary_lists(guard_selection_t *gs, guard->confirmed_on_date = 0; } else { if (BUG(smartlist_contains(gs->confirmed_entry_guards, guard))) { + // LCOV_EXCL_START smartlist_remove_keeporder(gs->confirmed_entry_guards, guard); + // LCOV_EXCL_STOP } } } @@ -903,10 +907,10 @@ STATIC void make_guard_confirmed(guard_selection_t *gs, entry_guard_t *guard) { if (BUG(guard->confirmed_on_date && guard->confirmed_idx >= 0)) - return; + return; // LCOV_EXCL_LINE if (BUG(smartlist_contains(gs->confirmed_entry_guards, guard))) - return; + return; // LCOV_EXCL_LINE const int GUARD_LIFETIME = GUARD_LIFETIME_DAYS * 86400; guard->confirmed_on_date = randomize_time(approx_time(), GUARD_LIFETIME/10); |