diff options
author | Nick Mathewson <nickm@torproject.org> | 2017-11-21 14:07:43 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-11-21 14:07:43 -0500 |
commit | bf882b037371d5ccb9eb1fc6c71199865169661b (patch) | |
tree | 39c2de688fc53f5af24ef89b425e8b7cbfd98461 /src | |
parent | 5da0a73838a210bac3be81baa9ade1d4ee7bf343 (diff) | |
download | tor-bf882b037371d5ccb9eb1fc6c71199865169661b.tar.gz tor-bf882b037371d5ccb9eb1fc6c71199865169661b.zip |
re-run ./scripts/maint/annotate_ifdef_directives
Diffstat (limited to 'src')
-rw-r--r-- | src/common/compat_threads.c | 2 | ||||
-rw-r--r-- | src/common/compat_threads.h | 8 | ||||
-rw-r--r-- | src/common/sandbox.c | 6 | ||||
-rw-r--r-- | src/or/config.c | 2 | ||||
-rw-r--r-- | src/or/confparse.h | 6 | ||||
-rw-r--r-- | src/or/git_revision.h | 2 | ||||
-rw-r--r-- | src/or/hs_circuit.h | 2 | ||||
-rw-r--r-- | src/or/main.c | 2 | ||||
-rw-r--r-- | src/or/protover.c | 2 | ||||
-rw-r--r-- | src/or/protover.h | 2 | ||||
-rw-r--r-- | src/or/protover_rust.c | 2 | ||||
-rw-r--r-- | src/or/tor_api_internal.h | 2 |
12 files changed, 19 insertions, 19 deletions
diff --git a/src/common/compat_threads.c b/src/common/compat_threads.c index e8a97f1254..6adcaab956 100644 --- a/src/common/compat_threads.c +++ b/src/common/compat_threads.c @@ -403,5 +403,5 @@ atomic_counter_exchange(atomic_counter_t *counter, size_t newval) tor_mutex_release(&counter->mutex); return oldval; } -#endif +#endif /* !defined(HAVE_STDATOMIC_H) */ diff --git a/src/common/compat_threads.h b/src/common/compat_threads.h index b452648ea5..ce86b15e9d 100644 --- a/src/common/compat_threads.h +++ b/src/common/compat_threads.h @@ -159,13 +159,13 @@ typedef struct atomic_counter_t { atomic_size_t val; } atomic_counter_t; #define ATOMIC_LINKAGE static -#else +#else /* !(defined(HAVE_STDATOMIC_H)) */ typedef struct atomic_counter_t { tor_mutex_t mutex; size_t val; } atomic_counter_t; #define ATOMIC_LINKAGE -#endif +#endif /* defined(HAVE_STDATOMIC_H) */ ATOMIC_LINKAGE void atomic_counter_init(atomic_counter_t *counter); ATOMIC_LINKAGE void atomic_counter_destroy(atomic_counter_t *counter); @@ -214,8 +214,8 @@ atomic_counter_exchange(atomic_counter_t *counter, size_t newval) return atomic_exchange(&counter->val, newval); } -#else -#endif +#else /* !(defined(HAVE_STDATOMIC_H)) */ +#endif /* defined(HAVE_STDATOMIC_H) */ #endif /* !defined(TOR_COMPAT_THREADS_H) */ diff --git a/src/common/sandbox.c b/src/common/sandbox.c index 92fdd60221..aec9857e94 100644 --- a/src/common/sandbox.c +++ b/src/common/sandbox.c @@ -429,9 +429,9 @@ libc_uses_openat_for_everything(void) return 1; else return 0; -#else +#else /* !(defined(CHECK_LIBC_VERSION)) */ return 0; -#endif +#endif /* defined(CHECK_LIBC_VERSION) */ } /** Allow a single file to be opened. If <b>use_openat</b> is true, @@ -1126,7 +1126,7 @@ sb_kill(scmp_filter_ctx ctx, sandbox_cfg_t *filter) SCMP_CMP(1, SCMP_CMP_EQ, 0)); #else return 0; -#endif +#endif /* defined(__NR_kill) */ } /** diff --git a/src/or/config.c b/src/or/config.c index b0a140d23b..f7383c89fa 100644 --- a/src/or/config.c +++ b/src/or/config.c @@ -1787,7 +1787,7 @@ options_act(const or_options_t *old_options) "given FD."); return -1; } -#endif +#endif /* defined(_WIN32) */ } /* Load state */ diff --git a/src/or/confparse.h b/src/or/confparse.h index 6f0b3b325c..022886e811 100644 --- a/src/or/confparse.h +++ b/src/or/confparse.h @@ -68,7 +68,7 @@ typedef union { config_line_t **LINELIST_V; routerset_t **ROUTERSET; } confparse_dummy_values_t; -#endif +#endif /* defined(TOR_UNIT_TESTS) */ /** An abbreviation for a configuration option allowed on the command line. */ typedef struct config_abbrev_t { @@ -132,13 +132,13 @@ typedef struct config_var_t { { NULL, CONFIG_TYPE_OBSOLETE, 0, NULL, { .INT=NULL } } #define DUMMY_TYPECHECK_INSTANCE(tp) \ static tp tp ## _dummy -#else +#else /* !(defined(TOR_UNIT_TESTS)) */ #define CONF_TEST_MEMBERS(tp, conftype, member) #define END_OF_CONFIG_VARS { NULL, CONFIG_TYPE_OBSOLETE, 0, NULL } /* Repeatedly declarable incomplete struct to absorb redundant semicolons */ #define DUMMY_TYPECHECK_INSTANCE(tp) \ struct tor_semicolon_eater -#endif +#endif /* defined(TOR_UNIT_TESTS) */ /** Type of a callback to validate whether a given configuration is * well-formed and consistent. See options_trial_assign() for documentation diff --git a/src/or/git_revision.h b/src/or/git_revision.h index 1ceaeedf16..5613cb4335 100644 --- a/src/or/git_revision.h +++ b/src/or/git_revision.h @@ -8,5 +8,5 @@ extern const char tor_git_revision[]; -#endif +#endif /* !defined(TOR_GIT_REVISION_H) */ diff --git a/src/or/hs_circuit.h b/src/or/hs_circuit.h index 0a1186dbaa..b92fb4e494 100644 --- a/src/or/hs_circuit.h +++ b/src/or/hs_circuit.h @@ -67,7 +67,7 @@ create_rp_circuit_identifier(const hs_service_t *service, const curve25519_public_key_t *server_pk, const hs_ntor_rend_cell_keys_t *keys); -#endif +#endif /* defined(HS_CIRCUIT_PRIVATE) */ #endif /* !defined(TOR_HS_CIRCUIT_H) */ diff --git a/src/or/main.c b/src/or/main.c index e349703918..dd7b0134ee 100644 --- a/src/or/main.c +++ b/src/or/main.c @@ -3207,7 +3207,7 @@ tor_init(int argc, char *argv[]) log_notice(LD_GENERAL, "%s", rust_str); } tor_free(rust_str); -#endif +#endif /* defined(HAVE_RUST) */ if (network_init()<0) { log_err(LD_BUG,"Error initializing network; exiting."); diff --git a/src/or/protover.c b/src/or/protover.c index ae955296e6..d6d14b24a2 100644 --- a/src/or/protover.c +++ b/src/or/protover.c @@ -778,5 +778,5 @@ protover_free_all(void) } } -#endif +#endif /* !defined(HAVE_RUST) */ diff --git a/src/or/protover.h b/src/or/protover.h index a4dbc8bfc2..83a728e626 100644 --- a/src/or/protover.h +++ b/src/or/protover.h @@ -84,7 +84,7 @@ STATIC const char *protocol_type_to_str(protocol_type_t pr); STATIC int str_to_protocol_type(const char *s, protocol_type_t *pr_out); STATIC void proto_entry_free(proto_entry_t *entry); -#endif +#endif /* !defined(HAVE_RUST) && defined(TOR_UNIT_TESTS) */ #endif /* defined(PROTOVER_PRIVATE) */ diff --git a/src/or/protover_rust.c b/src/or/protover_rust.c index 0c409b1681..26e21cc1c5 100644 --- a/src/or/protover_rust.c +++ b/src/or/protover_rust.c @@ -15,5 +15,5 @@ /* Define for compatibility, used in main.c */ void protover_free_all(void) {} -#endif +#endif /* defined(HAVE_RUST) */ diff --git a/src/or/tor_api_internal.h b/src/or/tor_api_internal.h index a69ba76420..10b6278b7b 100644 --- a/src/or/tor_api_internal.h +++ b/src/or/tor_api_internal.h @@ -16,5 +16,5 @@ struct tor_main_configuration_t { char **argv; }; -#endif +#endif /* !defined(TOR_API_INTERNAL_H) */ |