[tor-bugs] #24531 [Core Tor/Tor]: sched: Add function to change scheduler state and always use it

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Dec 5 15:10:51 UTC 2017


#24531: sched: Add function to change scheduler state and always use it
------------------------------+--------------------------------
     Reporter:  pastly        |      Owner:  (none)
         Type:  defect        |     Status:  new
     Priority:  Medium        |  Milestone:  Tor: 0.3.3.x-final
    Component:  Core Tor/Tor  |    Version:
     Severity:  Normal        |   Keywords:  tor-sched
Actual Points:                |  Parent ID:
       Points:                |   Reviewer:
      Sponsor:                |
------------------------------+--------------------------------
 I'm thinking about hypothetical future debugging efforts here.

 I think it would be nice to have

 {{{
 channel_set_scheduler_state(chan, new_state) {
   log_changed_from_state_to_state()
   chan->scheduler_state = new_state
 }
 }}}

 And then change every instance of `chan->scheduler_state = [...]` to
 `channel_set_scheduler_state([...])`. Future hypothetical debugging
 sessions can be guaranteed to have information regarding what state each
 channel at all times.

 Extra points if it logs some of the stuff in `scheduler_bug_occurred` too.

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/24531>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list