1. 27 Oct, 2020 1 commit
  2. 08 Jan, 2020 1 commit
  3. 05 Sep, 2019 1 commit
  4. 05 Jun, 2019 1 commit
  5. 30 Apr, 2019 2 commits
    • Nick Mathewson's avatar
      Rename and clarify some functions for periodic events · b7cc631d
      Nick Mathewson authored
      When we tell the periodic event manager about an event, we are
      "registering" that event.  The event sits around without being
      usable, however, until we "connect" the event to libevent.  In the
      end, we "disconnect" the event and remove its libevent parts.
      
      Previously, we called these operations "add", "setup", and
      "destroy", which led to confusion.
      b7cc631d
    • Nick Mathewson's avatar
      Turn 'mainloop' into a subsystem. · 6eb1b8da
      Nick Mathewson authored
      We need a little refactoring for this to work, since the
      initialization code for the periodic events assumes that libevent is
      already initialized, which it can't be until it's configured.
      
      This change, combined with the previous ones, lets other subsystems
      declare their own periodic events, without mainloop.c having to know
      about them.  Implements ticket 30293.
      6eb1b8da
  6. 25 Apr, 2019 1 commit
  7. 16 Jan, 2019 2 commits
  8. 15 Nov, 2018 3 commits
  9. 27 Sep, 2018 1 commit
    • Nick Mathewson's avatar
      Always initialize the periodic events list. · d0b2b5a2
      Nick Mathewson authored
      Various places in our code try to activate these events or check
      their status, so we should make sure they're initialized as early as
      possible.  Fixes bug 27861; bugfix on 0.3.5.1-alpha.
      d0b2b5a2
  10. 21 Sep, 2018 1 commit
    • Nick Mathewson's avatar
      Split main.c into main.c and mainloop.c · c7ce6b98
      Nick Mathewson authored
      The main.c code is responsible for initialization and shutdown;
      the mainloop.c code is responsible for running the main loop of Tor.
      
      Splitting the "generic event loop" part of mainloop.c from the
      event-loop-specific part is not done as part of this patch.
      c7ce6b98
  11. 02 Aug, 2018 1 commit
    • Nick Mathewson's avatar
      When enabling periodic events, schedule but don't run them immediately. · 176999fd
      Nick Mathewson authored
      When we fixed 25939 in f7633c1f, we
      introduced a call to rescan_periodic_events() from inside the onion
      service logic. But this meant that we could rescan the event list --
      thereby running event callbacks! -- from inside the hidden service code.
      This could cause us to run some of our event callbacks from an
      inconsistent state, if we were in the middle of changing options.
      
      A related bug (#25761) prevented us from rescanning our periodic
      events as appropriate, but when we fixed THAT one, this bug reared
      its ugly head.
      
      The fix here is that "enabling" an event should cause us to run it
      from the event loop, but not immediately from the point where we
      enable it.
      
      Fixes bug 27003; bugfix on 0.3.4.1-alpha.
      176999fd
  12. 05 Jul, 2018 1 commit
  13. 20 Jun, 2018 1 commit
  14. 30 Apr, 2018 1 commit
  15. 27 Apr, 2018 3 commits
  16. 23 Apr, 2018 1 commit