aboutsummaryrefslogtreecommitdiff
path: root/src/feature/hibernate
diff options
context:
space:
mode:
authorGeorge Kadianakis <desnacked@riseup.net>2019-03-13 14:54:01 +0200
committerteor <teor@torproject.org>2019-03-21 10:29:04 +1000
commitbc64fb4e33ff98ca7271ee369fef24b3cf693574 (patch)
tree3df58c3f67eaff215f5dcfe0f7207a8a8467c656 /src/feature/hibernate
parentfe78ba855a50c1f83e449d63d32e754bc988595a (diff)
downloadtor-bc64fb4e33ff98ca7271ee369fef24b3cf693574.tar.gz
tor-bc64fb4e33ff98ca7271ee369fef24b3cf693574.zip
circpad: Don't pad if Tor is in dormant mode.
This is something we should think about harder, but we probably want dormant mode to be more powerful than padding in case a client has been inactive for a day or so. After all, there are probably no circuits open at this point and dormant mode will not allow the client to open more circuits. Furthermore, padding should not block dormant mode from being activated, since dormant mode relies on SocksPort activity, and circuit padding does not mess with that.
Diffstat (limited to 'src/feature/hibernate')
-rw-r--r--src/feature/hibernate/hibernate.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/feature/hibernate/hibernate.h b/src/feature/hibernate/hibernate.h
index 3309ef0ce3..2e245f6ab1 100644
--- a/src/feature/hibernate/hibernate.h
+++ b/src/feature/hibernate/hibernate.h
@@ -32,6 +32,7 @@ int getinfo_helper_accounting(control_connection_t *conn,
const char **errmsg);
uint64_t get_accounting_max_total(void);
void accounting_free_all(void);
+bool accounting_tor_is_dormant(void);
#ifdef HIBERNATE_PRIVATE
/** Possible values of hibernate_state */