aboutsummaryrefslogtreecommitdiff
path: root/src/feature/relay/router.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-09-25 17:22:14 -0400
committerNick Mathewson <nickm@torproject.org>2018-09-25 17:22:14 -0400
commit3ff58e47d211d8649202c093f00934011effed1b (patch)
tree1243e4e4107a17a793c24a0b20691a10000d1a9d /src/feature/relay/router.c
parentb8df2318e9531a17938392cd0cbea0b901f50245 (diff)
downloadtor-3ff58e47d211d8649202c093f00934011effed1b.tar.gz
tor-3ff58e47d211d8649202c093f00934011effed1b.zip
Move the "is the network disabled?" functions out of router.c
Since this is completely core functionality, I'm putting it in core/mainloop, even though it depends on feature/hibernate. We'll have to sort that out in the future.
Diffstat (limited to 'src/feature/relay/router.c')
-rw-r--r--src/feature/relay/router.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/src/feature/relay/router.c b/src/feature/relay/router.c
index b3cfb6d8dd..05e3fb3b23 100644
--- a/src/feature/relay/router.c
+++ b/src/feature/relay/router.c
@@ -1311,24 +1311,6 @@ router_should_advertise_begindir(const or_options_t *options,
supports_tunnelled_dir_requests);
}
-/** Return true iff our network is in some sense disabled or shutting down:
- * either we're hibernating, entering hibernation, or the network is turned
- * off with DisableNetwork. */
-int
-net_is_disabled(void)
-{
- return get_options()->DisableNetwork || we_are_hibernating();
-}
-
-/** Return true iff our network is in some sense "completely disabled" either
- * we're fully hibernating or the network is turned off with
- * DisableNetwork. */
-int
-net_is_completely_disabled(void)
-{
- return get_options()->DisableNetwork || we_are_fully_hibernating();
-}
-
/** Return true iff the combination of options in <b>options</b> and parameters
* in the consensus mean that we don't want to allow exits from circuits
* we got from addresses not known to be servers. */