diff options
author | Nick Mathewson <nickm@torproject.org> | 2019-08-29 09:50:38 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2019-08-29 09:50:38 -0400 |
commit | 4256ee0d379daf35098c396757ce92b97b025c6e (patch) | |
tree | c5eebe3654a4cf3e1aa00a0e8cc10c56a28bebd5 /src/feature/dirauth/reachability.h | |
parent | ff905f8e1e3a9df9349a82cfa2724cc50b1523f4 (diff) | |
download | tor-4256ee0d379daf35098c396757ce92b97b025c6e.tar.gz tor-4256ee0d379daf35098c396757ce92b97b025c6e.zip |
Stub out some more functions in dirvote/*.h, fix compilation.
This fixes LTO compilation for Android and -O0 compilation in
general, when --disable-module-dirauth is provided.
Fixes bug 31552; bugfix on 0.4.1.1-alpha.
Diffstat (limited to 'src/feature/dirauth/reachability.h')
-rw-r--r-- | src/feature/dirauth/reachability.h | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/src/feature/dirauth/reachability.h b/src/feature/dirauth/reachability.h index 873a3f9a23..0018c7f638 100644 --- a/src/feature/dirauth/reachability.h +++ b/src/feature/dirauth/reachability.h @@ -28,9 +28,21 @@ void dirserv_orconn_tls_done(const tor_addr_t *addr, uint16_t or_port, const char *digest_rcvd, const struct ed25519_public_key_t *ed_id_rcvd); -int dirserv_should_launch_reachability_test(const routerinfo_t *ri, - const routerinfo_t *ri_old); void dirserv_single_reachability_test(time_t now, routerinfo_t *router); void dirserv_test_reachability(time_t now); +#ifdef HAVE_MODULE_DIRAUTH +int dirserv_should_launch_reachability_test(const routerinfo_t *ri, + const routerinfo_t *ri_old); +#else +static inline int +dirserv_should_launch_reachability_test(const routerinfo_t *ri, + const routerinfo_t *ri_old) +{ + (void)ri; + (void)ri_old; + return 0; +} +#endif + #endif /* !defined(TOR_REACHABILITY_H) */ |