commit 68a0106bf32988e1e085bbeaf843d3525e154c95 Author: Nick Mathewson nickm@torproject.org Date: Mon Sep 16 13:27:42 2019 -0400
Run "make autostyle" and fix wide lines. --- src/feature/dirauth/keypin.h | 2 +- src/feature/dirauth/process_descs.h | 4 ++-- src/feature/dirauth/reachability.h | 4 ++-- src/feature/hs/hs_dos.h | 2 +- src/feature/hs/hs_intropoint.c | 4 ++-- src/lib/confmgt/confparse.h | 2 +- src/lib/defs/logging_types.h | 2 +- src/lib/malloc/map_anon.c | 6 +++--- src/test/test_util.c | 2 +- 9 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/src/feature/dirauth/keypin.h b/src/feature/dirauth/keypin.h index ab2362b3f..1de84f6d4 100644 --- a/src/feature/dirauth/keypin.h +++ b/src/feature/dirauth/keypin.h @@ -29,7 +29,7 @@ keypin_load_journal(const char *fname) (void)fname; return 0; } -#endif +#endif /* defined(HAVE_MODULE_DIRAUTH) */ void keypin_clear(void); int keypin_check_lone_rsa(const uint8_t *rsa_id_digest);
diff --git a/src/feature/dirauth/process_descs.h b/src/feature/dirauth/process_descs.h index 184caa18b..9c9b2e354 100644 --- a/src/feature/dirauth/process_descs.h +++ b/src/feature/dirauth/process_descs.h @@ -38,7 +38,7 @@ uint32_t dirserv_router_get_status(const routerinfo_t *router, int severity); void dirserv_set_node_flags_from_authoritative_status(node_t *node, uint32_t authstatus); -#else +#else /* !(defined(HAVE_MODULE_DIRAUTH)) */ static inline int dirserv_load_fingerprint_file(void) { @@ -107,7 +107,7 @@ dirserv_set_node_flags_from_authoritative_status(node_t *node, (void)node; (void)authstatus; } -#endif +#endif /* defined(HAVE_MODULE_DIRAUTH) */
#ifdef TOR_UNIT_TESTS STATIC int dirserv_router_has_valid_address(routerinfo_t *ri); diff --git a/src/feature/dirauth/reachability.h b/src/feature/dirauth/reachability.h index 8a83f0c49..6624b516a 100644 --- a/src/feature/dirauth/reachability.h +++ b/src/feature/dirauth/reachability.h @@ -34,7 +34,7 @@ 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); -#else +#else /* !(defined(HAVE_MODULE_DIRAUTH)) */ static inline int dirserv_should_launch_reachability_test(const routerinfo_t *ri, const routerinfo_t *ri_old) @@ -54,6 +54,6 @@ dirserv_orconn_tls_done(const tor_addr_t *addr, (void)digest_rcvd; (void)ed_id_rcvd; } -#endif +#endif /* defined(HAVE_MODULE_DIRAUTH) */
#endif /* !defined(TOR_REACHABILITY_H) */ diff --git a/src/feature/hs/hs_dos.h b/src/feature/hs/hs_dos.h index 6647b24be..ccf4e2717 100644 --- a/src/feature/hs/hs_dos.h +++ b/src/feature/hs/hs_dos.h @@ -32,7 +32,7 @@ STATIC uint32_t get_intro2_enable_consensus_param(const networkstatus_t *ns); STATIC uint32_t get_intro2_rate_consensus_param(const networkstatus_t *ns); STATIC uint32_t get_intro2_burst_consensus_param(const networkstatus_t *ns);
-#endif /* define(TOR_UNIT_TESTS) */ +#endif /* defined(TOR_UNIT_TESTS) */
#endif /* defined(HS_DOS_PRIVATE) */
diff --git a/src/feature/hs/hs_intropoint.c b/src/feature/hs/hs_intropoint.c index 90a7f2894..fe8486b1a 100644 --- a/src/feature/hs/hs_intropoint.c +++ b/src/feature/hs/hs_intropoint.c @@ -200,7 +200,7 @@ cell_dos_extension_parameters_are_valid(uint64_t intro2_rate_per_sec, "too small. Received value: %" PRIu64, intro2_rate_per_sec); goto end; } -#endif +#endif /* HS_CONFIG_V3_DOS_DEFENSE_RATE_PER_SEC_MIN > 0 */
/* Check that received value is not above maximum */ if (intro2_rate_per_sec > HS_CONFIG_V3_DOS_DEFENSE_RATE_PER_SEC_MAX) { @@ -218,7 +218,7 @@ cell_dos_extension_parameters_are_valid(uint64_t intro2_rate_per_sec, "too small. Received value: %" PRIu64, intro2_burst_per_sec); goto end; } -#endif +#endif /* HS_CONFIG_V3_DOS_DEFENSE_BURST_PER_SEC_MIN > 0 */
/* Check that received value is not above maximum */ if (intro2_burst_per_sec > HS_CONFIG_V3_DOS_DEFENSE_BURST_PER_SEC_MAX) { diff --git a/src/lib/confmgt/confparse.h b/src/lib/confmgt/confparse.h index 054348d8d..2332f6979 100644 --- a/src/lib/confmgt/confparse.h +++ b/src/lib/confmgt/confparse.h @@ -207,6 +207,6 @@ STATIC void *config_mgr_get_obj_mutable(const config_mgr_t *mgr, void *toplevel, int idx); STATIC const void *config_mgr_get_obj(const config_mgr_t *mgr, const void *toplevel, int idx); -#endif +#endif /* defined(CONFPARSE_PRIVATE) */
#endif /* !defined(TOR_CONFPARSE_H) */ diff --git a/src/lib/defs/logging_types.h b/src/lib/defs/logging_types.h index 57db81800..d3eacde46 100644 --- a/src/lib/defs/logging_types.h +++ b/src/lib/defs/logging_types.h @@ -20,4 +20,4 @@ /** Mask of zero or more log domains, OR'd together. */ typedef uint64_t log_domain_mask_t;
-#endif +#endif /* !defined(TOR_LOGGING_TYPES_H) */ diff --git a/src/lib/malloc/map_anon.c b/src/lib/malloc/map_anon.c index ae4edff76..22190070b 100644 --- a/src/lib/malloc/map_anon.c +++ b/src/lib/malloc/map_anon.c @@ -122,7 +122,7 @@ nodump_mem(void *mem, size_t sz) NULL); return -1; } -#else +#else /* !(defined(MADV_DONTDUMP)) */ (void) mem; (void) sz; return 0; @@ -170,12 +170,12 @@ noinherit_mem(void *mem, size_t sz, inherit_res_t *inherit_result_out) NULL); return -1; } -#else +#else /* !(defined(FLAG_ZERO) || defined(FLAG_NOINHERIT)) */ (void)inherit_result_out; (void)mem; (void)sz; return 0; -#endif +#endif /* defined(FLAG_ZERO) || defined(FLAG_NOINHERIT) */ }
/** diff --git a/src/test/test_util.c b/src/test/test_util.c index c56d3488b..84834f4d6 100644 --- a/src/test/test_util.c +++ b/src/test/test_util.c @@ -5405,7 +5405,7 @@ test_util_socketpair(void *arg) * all. */ tt_skip(); } -#endif +#endif /* defined(ENETUNREACH) */ tt_int_op(0, OP_EQ, socketpair_result);
tt_assert(SOCKET_OK(fds[0]));
tor-commits@lists.torproject.org