diff options
author | Nick Mathewson <nickm@torproject.org> | 2018-11-13 15:33:46 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2018-11-15 11:17:22 -0500 |
commit | 2c15b6538123047c258987b00475fa658ca14878 (patch) | |
tree | 6a01a36619cd1df7228b9a50e20a15087d3e014e /src/core/mainloop/netstatus.h | |
parent | ccbb36048f5167b9d5011b7c8b0d2c346ce567e8 (diff) | |
download | tor-2c15b6538123047c258987b00475fa658ca14878.tar.gz tor-2c15b6538123047c258987b00475fa658ca14878.zip |
Make the NET_PARTICIPANT role dependent on user activity
This patch implements all of 28337, except for the part where we
turn off the role if we've been idle for a long time.
Diffstat (limited to 'src/core/mainloop/netstatus.h')
-rw-r--r-- | src/core/mainloop/netstatus.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/core/mainloop/netstatus.h b/src/core/mainloop/netstatus.h index e9310c2929..58c994fd14 100644 --- a/src/core/mainloop/netstatus.h +++ b/src/core/mainloop/netstatus.h @@ -10,4 +10,11 @@ int net_is_disabled(void); int net_is_completely_disabled(void); +void note_user_activity(time_t now); +void reset_user_activity(time_t now); +time_t get_last_user_activity_time(void); + +void set_network_participation(bool participation); +bool is_participating_on_network(void); + #endif |