[tor-bugs] #24649 [Core Tor/Tor]: Simplify bridge code: do we still need mark-unmark-and-sweep logic?
Tor Bug Tracker & Wiki
blackhole at torproject.org
Sun Dec 17 16:50:25 UTC 2017
#24649: Simplify bridge code: do we still need mark-unmark-and-sweep logic?
----------------------------+----------------------------------------------
Reporter: nickm | Owner: (none)
Type: defect | Status: new
Priority: Medium | Milestone: Tor: unspecified
Component: Core | Version:
Tor/Tor |
Severity: Normal | Keywords: refactoring code-removal bridges
Actual Points: | Parent ID:
Points: | Reviewer:
Sponsor: |
----------------------------+----------------------------------------------
In an older version of the bridge code, we would encode some state
information in the bridge_info_t object. Therefore, when we reloaded the
configuration, it was important that we use the old object for any bridges
that we still had. For that reason, we would (on reloading the
configuration) first mark all bridges, then unmark any bridges that were
still in the configuration (while adding any new bridges), and finally
we'd free all the marked bridges.
But, looking at the code now, it appears we no longer take this approach:
once marked_for_removal is set on a bridge, nothing clears it. If that's
the case, we could simplify our bridge configuration logic a bit by just
clearing the bridge list and rebuilding it, and dropping this whole
"marked_for_removal" business.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/24649>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list