mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-27 22:03:31 +01:00
Run "make autostyle."
This commit is contained in:
parent
d1b02456c1
commit
60213a3621
@ -3551,7 +3551,7 @@ options_validate(or_options_t *old_options, or_options_t *options,
|
|||||||
tor_free(t);
|
tor_free(t);
|
||||||
t = format_recommended_version_list(options->RecommendedServerVersions, 1);
|
t = format_recommended_version_list(options->RecommendedServerVersions, 1);
|
||||||
tor_free(t);
|
tor_free(t);
|
||||||
#endif
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
|
|
||||||
if (options->UseEntryGuards) {
|
if (options->UseEntryGuards) {
|
||||||
log_info(LD_CONFIG, "Authoritative directory servers can't set "
|
log_info(LD_CONFIG, "Authoritative directory servers can't set "
|
||||||
@ -3577,7 +3577,7 @@ options_validate(or_options_t *old_options, or_options_t *options,
|
|||||||
if (options->GuardfractionFile && !old_options) {
|
if (options->GuardfractionFile && !old_options) {
|
||||||
dirserv_read_guardfraction_file(options->GuardfractionFile, NULL);
|
dirserv_read_guardfraction_file(options->GuardfractionFile, NULL);
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
}
|
}
|
||||||
|
|
||||||
if (options->AuthoritativeDir && !options->DirPort_set)
|
if (options->AuthoritativeDir && !options->DirPort_set)
|
||||||
@ -4605,7 +4605,7 @@ compute_real_max_mem_in_queues(const uint64_t val, int log_guess)
|
|||||||
#else
|
#else
|
||||||
/* On a 32-bit platform, we can't have 8GB of ram. */
|
/* On a 32-bit platform, we can't have 8GB of ram. */
|
||||||
#define RAM_IS_VERY_LARGE(x) (0)
|
#define RAM_IS_VERY_LARGE(x) (0)
|
||||||
#endif
|
#endif /* SIZEOF_SIZE_T > 4 */
|
||||||
|
|
||||||
if (RAM_IS_VERY_LARGE(ram)) {
|
if (RAM_IS_VERY_LARGE(ram)) {
|
||||||
/* If we have 8 GB, or more, RAM available, we set the MaxMemInQueues
|
/* If we have 8 GB, or more, RAM available, we set the MaxMemInQueues
|
||||||
@ -5777,7 +5777,7 @@ options_init_logs(const or_options_t *old_options, or_options_t *options,
|
|||||||
#else
|
#else
|
||||||
log_warn(LD_CONFIG, "Android logging is not supported"
|
log_warn(LD_CONFIG, "Android logging is not supported"
|
||||||
" on this system. Sorry.");
|
" on this system. Sorry.");
|
||||||
#endif // HAVE_ANDROID_LOG_H.
|
#endif /* defined(HAVE_ANDROID_LOG_H) */
|
||||||
goto cleanup;
|
goto cleanup;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1110,4 +1110,4 @@ struct or_options_t {
|
|||||||
int DormantCanceledByStartup;
|
int DormantCanceledByStartup;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_OR_OPTIONS_ST_H) */
|
||||||
|
@ -96,4 +96,4 @@ struct or_state_t {
|
|||||||
int Dormant;
|
int Dormant;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_OR_STATE_ST_H) */
|
||||||
|
@ -31,6 +31,6 @@ STATIC struct config_line_t *get_transport_in_state_by_name(
|
|||||||
STATIC void or_state_free_(or_state_t *state);
|
STATIC void or_state_free_(or_state_t *state);
|
||||||
#define or_state_free(st) FREE_AND_NULL(or_state_t, or_state_free_, (st))
|
#define or_state_free(st) FREE_AND_NULL(or_state_t, or_state_free_, (st))
|
||||||
STATIC or_state_t *or_state_new(void);
|
STATIC or_state_t *or_state_new(void);
|
||||||
#endif
|
#endif /* defined(STATEFILE_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_STATEFILE_H) */
|
#endif /* !defined(TOR_STATEFILE_H) */
|
||||||
|
@ -26,4 +26,4 @@ void subsystems_prefork(void);
|
|||||||
void subsystems_postfork(void);
|
void subsystems_postfork(void);
|
||||||
void subsystems_thread_cleanup(void);
|
void subsystems_thread_cleanup(void);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_SUBSYSMGR_T) */
|
||||||
|
@ -44,4 +44,4 @@ void server_onion_keys_free_(server_onion_keys_t *keys);
|
|||||||
#define server_onion_keys_free(keys) \
|
#define server_onion_keys_free(keys) \
|
||||||
FREE_AND_NULL(server_onion_keys_t, server_onion_keys_free_, (keys))
|
FREE_AND_NULL(server_onion_keys_t, server_onion_keys_free_, (keys))
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_ONION_CRYPTO_H) */
|
||||||
|
@ -1476,7 +1476,7 @@ connection_listener_new(const struct sockaddr *listensockaddr,
|
|||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif /* __APPLE__ */
|
#endif /* !defined(__APPLE__) */
|
||||||
#endif /* defined(HAVE_SYS_UN_H) */
|
#endif /* defined(HAVE_SYS_UN_H) */
|
||||||
} else {
|
} else {
|
||||||
log_err(LD_BUG, "Got unexpected address family %d.",
|
log_err(LD_BUG, "Got unexpected address family %d.",
|
||||||
@ -2856,7 +2856,7 @@ retry_listener_ports(smartlist_t *old_conns,
|
|||||||
SMARTLIST_DEL_CURRENT(old_conns, conn);
|
SMARTLIST_DEL_CURRENT(old_conns, conn);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* defined(ENABLE_LISTENER_REBIND) */
|
||||||
}
|
}
|
||||||
} SMARTLIST_FOREACH_END(wanted);
|
} SMARTLIST_FOREACH_END(wanted);
|
||||||
|
|
||||||
@ -2958,7 +2958,7 @@ retry_all_listeners(smartlist_t *new_conns, int close_all_noncontrol)
|
|||||||
conn_type_to_string(old_conn->type), old_conn->address,
|
conn_type_to_string(old_conn->type), old_conn->address,
|
||||||
old_conn->port, new_conn->address, new_conn->port);
|
old_conn->port, new_conn->address, new_conn->port);
|
||||||
} SMARTLIST_FOREACH_END(r);
|
} SMARTLIST_FOREACH_END(r);
|
||||||
#endif
|
#endif /* defined(ENABLE_LISTENER_REBIND) */
|
||||||
|
|
||||||
/* Any members that were still in 'listeners' don't correspond to
|
/* Any members that were still in 'listeners' don't correspond to
|
||||||
* any configured port. Kill 'em. */
|
* any configured port. Kill 'em. */
|
||||||
@ -3957,9 +3957,9 @@ update_send_buffer_size(tor_socket_t sock)
|
|||||||
&isb, sizeof(isb), &bytesReturned, NULL, NULL)) {
|
&isb, sizeof(isb), &bytesReturned, NULL, NULL)) {
|
||||||
setsockopt(sock, SOL_SOCKET, SO_SNDBUF, (const char*)&isb, sizeof(isb));
|
setsockopt(sock, SOL_SOCKET, SO_SNDBUF, (const char*)&isb, sizeof(isb));
|
||||||
}
|
}
|
||||||
#else
|
#else /* !(defined(_WIN32)) */
|
||||||
(void) sock;
|
(void) sock;
|
||||||
#endif
|
#endif /* defined(_WIN32) */
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Try to flush more bytes onto <b>conn</b>-\>s.
|
/** Try to flush more bytes onto <b>conn</b>-\>s.
|
||||||
|
@ -754,7 +754,7 @@ tor_shutdown_event_loop_for_restart_cb(
|
|||||||
tor_event_free(tor_shutdown_event_loop_for_restart_event);
|
tor_event_free(tor_shutdown_event_loop_for_restart_event);
|
||||||
tor_shutdown_event_loop_and_exit(0);
|
tor_shutdown_event_loop_and_exit(0);
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* defined(ENABLE_RESTART_DEBUGGING) */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* After finishing the current callback (if any), shut down the main loop,
|
* After finishing the current callback (if any), shut down the main loop,
|
||||||
@ -2375,7 +2375,7 @@ do_main_loop(void)
|
|||||||
event_add(tor_shutdown_event_loop_for_restart_event, &restart_after);
|
event_add(tor_shutdown_event_loop_for_restart_event, &restart_after);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* defined(ENABLE_RESTART_DEBUGGING) */
|
||||||
|
|
||||||
return run_main_loop_until_done();
|
return run_main_loop_until_done();
|
||||||
}
|
}
|
||||||
|
@ -112,7 +112,7 @@ extern smartlist_t *connection_array;
|
|||||||
/* We need the periodic_event_item_t definition. */
|
/* We need the periodic_event_item_t definition. */
|
||||||
#include "core/mainloop/periodic.h"
|
#include "core/mainloop/periodic.h"
|
||||||
extern periodic_event_item_t mainloop_periodic_events[];
|
extern periodic_event_item_t mainloop_periodic_events[];
|
||||||
#endif
|
#endif /* defined(TOR_UNIT_TESTS) */
|
||||||
#endif /* defined(MAIN_PRIVATE) */
|
#endif /* defined(MAINLOOP_PRIVATE) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_MAINLOOP_H) */
|
||||||
|
@ -6,9 +6,9 @@
|
|||||||
|
|
||||||
#include "orconfig.h"
|
#include "orconfig.h"
|
||||||
|
|
||||||
#include "src/core/or/or.h"
|
#include "core/or/or.h"
|
||||||
#include "src/core/mainloop/mainloop.h"
|
#include "core/mainloop/mainloop.h"
|
||||||
#include "src/core/mainloop/mainloop_pubsub.h"
|
#include "core/mainloop/mainloop_pubsub.h"
|
||||||
|
|
||||||
#include "lib/container/smartlist.h"
|
#include "lib/container/smartlist.h"
|
||||||
#include "lib/dispatch/dispatch.h"
|
#include "lib/dispatch/dispatch.h"
|
||||||
|
@ -21,4 +21,4 @@ int tor_mainloop_set_delivery_strategy(const char *msg_channel_name,
|
|||||||
deliv_strategy_t strategy);
|
deliv_strategy_t strategy);
|
||||||
void tor_mainloop_disconnect_pubsub(void);
|
void tor_mainloop_disconnect_pubsub(void);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_MAINLOOP_PUBSUB_H) */
|
||||||
|
@ -9,4 +9,4 @@
|
|||||||
|
|
||||||
extern const struct subsys_fns_t sys_mainloop;
|
extern const struct subsys_fns_t sys_mainloop;
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(MAINLOOP_SYS_H) */
|
||||||
|
@ -21,4 +21,4 @@ void netstatus_flush_to_state(or_state_t *state, time_t now);
|
|||||||
void netstatus_load_from_state(const or_state_t *state, time_t now);
|
void netstatus_load_from_state(const or_state_t *state, time_t now);
|
||||||
void netstatus_note_clock_jumped(time_t seconds_diff);
|
void netstatus_note_clock_jumped(time_t seconds_diff);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_NETSTATUS_H) */
|
||||||
|
@ -43,4 +43,4 @@ struct addr_policy_t {
|
|||||||
uint16_t prt_max; /**< Highest port number to accept/reject. */
|
uint16_t prt_max; /**< Highest port number to accept/reject. */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_ADDR_POLICY_ST_H) */
|
||||||
|
@ -28,4 +28,4 @@ void address_set_add_ipv4h(address_set_t *set, uint32_t addr);
|
|||||||
int address_set_probably_contains(const address_set_t *set,
|
int address_set_probably_contains(const address_set_t *set,
|
||||||
const struct tor_addr_t *addr);
|
const struct tor_addr_t *addr);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_ADDRESS_SET_H) */
|
||||||
|
@ -26,4 +26,4 @@ struct cell_queue_t {
|
|||||||
int n; /**< The number of cells in the queue. */
|
int n; /**< The number of cells in the queue. */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(PACKED_CELL_ST_H) */
|
||||||
|
@ -16,5 +16,5 @@ struct cell_t {
|
|||||||
uint8_t payload[CELL_PAYLOAD_SIZE]; /**< Cell body. */
|
uint8_t payload[CELL_PAYLOAD_SIZE]; /**< Cell body. */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CELL_ST_H) */
|
||||||
|
|
||||||
|
@ -229,4 +229,4 @@ struct circuit_t {
|
|||||||
struct circpad_machine_runtime_t *padding_info[CIRCPAD_MAX_MACHINES];
|
struct circpad_machine_runtime_t *padding_info[CIRCPAD_MAX_MACHINES];
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CIRCUIT_ST_H) */
|
||||||
|
@ -2595,7 +2595,7 @@ circpad_circ_responder_machine_init(void)
|
|||||||
circpad_register_padding_machine(circ_responder_machine,
|
circpad_register_padding_machine(circ_responder_machine,
|
||||||
relay_padding_machines);
|
relay_padding_machines);
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* defined(TOR_UNIT_TESTS) */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize all of our padding machines.
|
* Initialize all of our padding machines.
|
||||||
@ -2977,4 +2977,4 @@ circpad_string_to_machine(const char *str)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif /* 0 */
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
#ifndef TOR_CIRCUITPADDING_H
|
#ifndef TOR_CIRCUITPADDING_H
|
||||||
#define TOR_CIRCUITPADDING_H
|
#define TOR_CIRCUITPADDING_H
|
||||||
|
|
||||||
#include "src/trunnel/circpad_negotiation.h"
|
#include "trunnel/circpad_negotiation.h"
|
||||||
#include "lib/evloop/timers.h"
|
#include "lib/evloop/timers.h"
|
||||||
|
|
||||||
struct circuit_t;
|
struct circuit_t;
|
||||||
@ -803,6 +803,6 @@ extern smartlist_t *relay_padding_machines;
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif /* defined(CIRCUITPADDING_PRIVATE) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_CIRCUITPADDING_H) */
|
||||||
|
@ -30,6 +30,6 @@ void circpad_machine_client_hide_rend_circuits(smartlist_t *machines_sl);
|
|||||||
* The actual value will be sampled between the min and max.*/
|
* The actual value will be sampled between the min and max.*/
|
||||||
#define INTRO_MACHINE_MAXIMUM_PADDING 10
|
#define INTRO_MACHINE_MAXIMUM_PADDING 10
|
||||||
|
|
||||||
#endif
|
#endif /* defined(CIRCUITPADDING_MACHINES_PRIVATE) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_CIRCUITPADDING_MACHINES_H) */
|
||||||
|
@ -146,4 +146,4 @@ struct connection_t {
|
|||||||
* directory connection. */
|
* directory connection. */
|
||||||
#define DIR_CONN_IS_SERVER(conn) ((conn)->purpose == DIR_PURPOSE_SERVER)
|
#define DIR_CONN_IS_SERVER(conn) ((conn)->purpose == DIR_PURPOSE_SERVER)
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CONNECTION_ST_H) */
|
||||||
|
@ -34,5 +34,5 @@ struct cpath_build_state_t {
|
|||||||
time_t expiry_time;
|
time_t expiry_time;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CIRCUIT_BUILD_STATE_ST_ST_H) */
|
||||||
|
|
||||||
|
@ -43,4 +43,4 @@ uint8_t *cpath_get_sendme_digest(crypt_path_t *cpath);
|
|||||||
unsigned int cpath_get_n_hops(crypt_path_t **head_ptr);
|
unsigned int cpath_get_n_hops(crypt_path_t **head_ptr);
|
||||||
#endif /* defined(TOR_UNIT_TESTS) */
|
#endif /* defined(TOR_UNIT_TESTS) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CRYPT_PATH_H) */
|
||||||
|
@ -19,5 +19,5 @@ struct crypt_path_reference_t {
|
|||||||
crypt_path_t *cpath;
|
crypt_path_t *cpath;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CRYPT_PATH_REFERENCE_ST_H) */
|
||||||
|
|
||||||
|
@ -35,7 +35,7 @@ struct onion_handshake_state_t {
|
|||||||
/* Helper macro to access private members of a struct. */
|
/* Helper macro to access private members of a struct. */
|
||||||
#define pvt_crypto CRYPT_PATH_PRIV_FIELD(crypto)
|
#define pvt_crypto CRYPT_PATH_PRIV_FIELD(crypto)
|
||||||
|
|
||||||
#endif
|
#endif /* defined(CRYPT_PATH_PRIVATE) */
|
||||||
|
|
||||||
/** Holds accounting information for a single step in the layered encryption
|
/** Holds accounting information for a single step in the layered encryption
|
||||||
* performed by a circuit. Used only at the client edge of a circuit. */
|
* performed by a circuit. Used only at the client edge of a circuit. */
|
||||||
@ -82,4 +82,4 @@ struct crypt_path_t {
|
|||||||
relay_crypto_t CRYPT_PATH_PRIV_FIELD(crypto);
|
relay_crypto_t CRYPT_PATH_PRIV_FIELD(crypto);
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CRYPT_PATH_ST_H) */
|
||||||
|
@ -23,5 +23,5 @@ struct destroy_cell_queue_t {
|
|||||||
int n; /**< The number of cells in the queue. */
|
int n; /**< The number of cells in the queue. */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(DESTROY_CELL_QUEUE_ST_H) */
|
||||||
|
|
||||||
|
@ -134,7 +134,7 @@ MOCK_DECL(STATIC unsigned int, get_param_cc_enabled,
|
|||||||
MOCK_DECL(STATIC unsigned int, get_param_conn_enabled,
|
MOCK_DECL(STATIC unsigned int, get_param_conn_enabled,
|
||||||
(const networkstatus_t *ns));
|
(const networkstatus_t *ns));
|
||||||
|
|
||||||
#endif /* TOR_DOS_PRIVATE */
|
#endif /* defined(DOS_PRIVATE) */
|
||||||
|
|
||||||
#endif /* TOR_DOS_H */
|
#endif /* !defined(TOR_DOS_H) */
|
||||||
|
|
||||||
|
@ -73,5 +73,5 @@ struct edge_connection_t {
|
|||||||
uint64_t dirreq_id;
|
uint64_t dirreq_id;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(EDGE_CONNECTION_ST_H) */
|
||||||
|
|
||||||
|
@ -96,5 +96,5 @@ struct entry_connection_t {
|
|||||||
/** Cast a entry_connection_t subtype pointer to a edge_connection_t **/
|
/** Cast a entry_connection_t subtype pointer to a edge_connection_t **/
|
||||||
#define ENTRY_TO_EDGE_CONN(c) (&(((c))->edge_))
|
#define ENTRY_TO_EDGE_CONN(c) (&(((c))->edge_))
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(ENTRY_CONNECTION_ST_H) */
|
||||||
|
|
||||||
|
@ -50,5 +50,5 @@ struct entry_port_cfg_t {
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(ENTRY_PORT_CFG_ST_H) */
|
||||||
|
|
||||||
|
@ -27,4 +27,4 @@ struct extend_info_t {
|
|||||||
curve25519_public_key_t curve25519_onion_key;
|
curve25519_public_key_t curve25519_onion_key;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(EXTEND_INFO_ST_H) */
|
||||||
|
@ -30,5 +30,5 @@ typedef struct half_edge_t {
|
|||||||
int connected_pending : 1;
|
int connected_pending : 1;
|
||||||
} half_edge_t;
|
} half_edge_t;
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(HALF_EDGE_ST_H) */
|
||||||
|
|
||||||
|
@ -21,5 +21,5 @@ struct listener_connection_t {
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(LISTENER_CONNECTION_ST_H) */
|
||||||
|
|
||||||
|
@ -86,4 +86,4 @@ void ocirc_event_subscribe(ocirc_event_rcvr_t fn);
|
|||||||
void ocirc_event_publish(const ocirc_event_msg_t *msg);
|
void ocirc_event_publish(const ocirc_event_msg_t *msg);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* defined(TOR_OCIRC_EVENT_STATE_H) */
|
#endif /* !defined(TOR_OCIRC_EVENT_H) */
|
||||||
|
@ -10,4 +10,4 @@
|
|||||||
|
|
||||||
extern const struct subsys_fns_t sys_ocirc_event;
|
extern const struct subsys_fns_t sys_ocirc_event;
|
||||||
|
|
||||||
#endif /* defined(TOR_OCIRC_EVENT_H) */
|
#endif /* !defined(TOR_OCIRC_EVENT_SYS_H) */
|
||||||
|
@ -71,5 +71,5 @@ struct or_circuit_t {
|
|||||||
uint64_t total_cell_waiting_time;
|
uint64_t total_cell_waiting_time;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(OR_CIRCUIT_ST_H) */
|
||||||
|
|
||||||
|
@ -91,4 +91,4 @@ struct or_connection_t {
|
|||||||
uint64_t bytes_xmitted, bytes_xmitted_by_tls;
|
uint64_t bytes_xmitted, bytes_xmitted_by_tls;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(OR_CONNECTION_ST_H) */
|
||||||
|
@ -37,4 +37,4 @@ struct or_handshake_certs_t {
|
|||||||
size_t ed_rsa_crosscert_len;
|
size_t ed_rsa_crosscert_len;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(OR_HANDSHAKE_CERTS_ST) */
|
||||||
|
@ -74,5 +74,5 @@ struct or_handshake_state_t {
|
|||||||
or_handshake_certs_t *certs;
|
or_handshake_certs_t *certs;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(OR_HANDSHAKE_STATE_ST) */
|
||||||
|
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
#include "core/or/circuituse.h"
|
#include "core/or/circuituse.h"
|
||||||
#include "core/or/or_periodic.h"
|
#include "core/or/or_periodic.h"
|
||||||
|
|
||||||
#include "src/feature/relay/routermode.h"
|
#include "feature/relay/routermode.h"
|
||||||
|
|
||||||
#define DECLARE_EVENT(name, roles, flags) \
|
#define DECLARE_EVENT(name, roles, flags) \
|
||||||
static periodic_event_item_t name ## _event = \
|
static periodic_event_item_t name ## _event = \
|
||||||
|
@ -117,4 +117,4 @@ void orconn_event_subscribe(orconn_event_rcvr_t);
|
|||||||
void orconn_event_publish(const orconn_event_msg_t *);
|
void orconn_event_publish(const orconn_event_msg_t *);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* defined(TOR_ORCONN_EVENT_H) */
|
#endif /* !defined(TOR_ORCONN_EVENT_H) */
|
||||||
|
@ -9,4 +9,4 @@
|
|||||||
|
|
||||||
extern const struct subsys_fns_t sys_orconn_event;
|
extern const struct subsys_fns_t sys_orconn_event;
|
||||||
|
|
||||||
#endif /* defined(TOR_ORCONN_SYS_H) */
|
#endif /* !defined(TOR_ORCONN_EVENT_SYS_H) */
|
||||||
|
@ -295,4 +295,4 @@ struct origin_circuit_t {
|
|||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(ORIGIN_CIRCUIT_ST_H) */
|
||||||
|
@ -31,5 +31,5 @@ struct port_cfg_t {
|
|||||||
char unix_addr[FLEXIBLE_ARRAY_MEMBER];
|
char unix_addr[FLEXIBLE_ARRAY_MEMBER];
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(PORT_CFG_ST_H) */
|
||||||
|
|
||||||
|
@ -30,4 +30,4 @@ struct relay_crypto_t {
|
|||||||
};
|
};
|
||||||
#undef crypto_cipher_t
|
#undef crypto_cipher_t
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(RELAY_CRYPTO_ST_H) */
|
||||||
|
@ -73,8 +73,8 @@ STATIC bool sendme_is_valid(const circuit_t *circ,
|
|||||||
const uint8_t *cell_payload,
|
const uint8_t *cell_payload,
|
||||||
size_t cell_payload_len);
|
size_t cell_payload_len);
|
||||||
|
|
||||||
#endif /* TOR_UNIT_TESTS */
|
#endif /* defined(TOR_UNIT_TESTS) */
|
||||||
|
|
||||||
#endif /* SENDME_PRIVATE */
|
#endif /* defined(SENDME_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_SENDME_H) */
|
#endif /* !defined(TOR_SENDME_H) */
|
||||||
|
@ -16,5 +16,5 @@ struct server_port_cfg_t {
|
|||||||
unsigned int bind_ipv6_only : 1;
|
unsigned int bind_ipv6_only : 1;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(SERVER_PORT_CFG_ST_H) */
|
||||||
|
|
||||||
|
@ -74,4 +74,4 @@ struct socks_request_t {
|
|||||||
uint8_t socks5_atyp; /* SOCKS5 address type */
|
uint8_t socks5_atyp; /* SOCKS5 address type */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(SOCKS_REQUEST_ST_H) */
|
||||||
|
@ -28,5 +28,5 @@ struct tor_version_t {
|
|||||||
char git_tag[DIGEST_LEN];
|
char git_tag[DIGEST_LEN];
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_VERSION_ST_H) */
|
||||||
|
|
||||||
|
@ -19,5 +19,5 @@ struct var_cell_t {
|
|||||||
uint8_t payload[FLEXIBLE_ARRAY_MEMBER];
|
uint8_t payload[FLEXIBLE_ARRAY_MEMBER];
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(VAR_CELL_ST_H) */
|
||||||
|
|
||||||
|
@ -40,10 +40,10 @@
|
|||||||
#define raw_socketpair tor_ersatz_socketpair
|
#define raw_socketpair tor_ersatz_socketpair
|
||||||
#define raw_closesocket closesocket
|
#define raw_closesocket closesocket
|
||||||
#define snprintf _snprintf
|
#define snprintf _snprintf
|
||||||
#else
|
#else /* !(defined(_WIN32)) */
|
||||||
#define raw_socketpair socketpair
|
#define raw_socketpair socketpair
|
||||||
#define raw_closesocket close
|
#define raw_closesocket close
|
||||||
#endif
|
#endif /* defined(_WIN32) */
|
||||||
|
|
||||||
#ifdef HAVE_UNISTD_H
|
#ifdef HAVE_UNISTD_H
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
@ -55,7 +55,7 @@ typedef SOCKET tor_control_socket_t;
|
|||||||
#else
|
#else
|
||||||
typedef int tor_control_socket_t;
|
typedef int tor_control_socket_t;
|
||||||
#define INVALID_TOR_CONTROL_SOCKET (-1)
|
#define INVALID_TOR_CONTROL_SOCKET (-1)
|
||||||
#endif
|
#endif /* defined(_WIN32) */
|
||||||
|
|
||||||
/** DOCDOC */
|
/** DOCDOC */
|
||||||
tor_control_socket_t tor_main_configuration_setup_control_socket(
|
tor_control_socket_t tor_main_configuration_setup_control_socket(
|
||||||
|
@ -12,4 +12,4 @@
|
|||||||
int btrack_circ_init(void);
|
int btrack_circ_init(void);
|
||||||
void btrack_circ_fini(void);
|
void btrack_circ_fini(void);
|
||||||
|
|
||||||
#endif /* defined(TOR_BTRACK_CIRCUIT_H) */
|
#endif /* !defined(TOR_BTRACK_CIRCUIT_H) */
|
||||||
|
@ -30,9 +30,9 @@ typedef struct bt_orconn_t {
|
|||||||
bool is_onehop; /**< Is this for a one-hop circuit? */
|
bool is_onehop; /**< Is this for a one-hop circuit? */
|
||||||
} bt_orconn_t;
|
} bt_orconn_t;
|
||||||
|
|
||||||
#endif /* defined(BTRACK_ORCONN_PRIVATE) */
|
#endif /* defined(BTRACK_ORCONN_PRIVATE) */
|
||||||
|
|
||||||
int btrack_orconn_init(void);
|
int btrack_orconn_init(void);
|
||||||
void btrack_orconn_fini(void);
|
void btrack_orconn_fini(void);
|
||||||
|
|
||||||
#endif /* defined(TOR_BTRACK_ORCONN_H) */
|
#endif /* !defined(TOR_BTRACK_ORCONN_H) */
|
||||||
|
@ -15,4 +15,4 @@ void bto_cevent_anyconn(const bt_orconn_t *);
|
|||||||
void bto_cevent_apconn(const bt_orconn_t *);
|
void bto_cevent_apconn(const bt_orconn_t *);
|
||||||
void bto_cevent_reset(void);
|
void bto_cevent_reset(void);
|
||||||
|
|
||||||
#endif /* defined(TOR_BTRACK_ORCONN_CEVENT_H) */
|
#endif /* !defined(TOR_BTRACK_ORCONN_CEVENT_H) */
|
||||||
|
@ -15,4 +15,4 @@ bt_orconn_t *bto_find_or_new(uint64_t, uint64_t);
|
|||||||
void bto_init_maps(void);
|
void bto_init_maps(void);
|
||||||
void bto_clear_maps(void);
|
void bto_clear_maps(void);
|
||||||
|
|
||||||
#endif /* defined(TOR_BTRACK_ORCONN_MAPS_H) */
|
#endif /* !defined(TOR_BTRACK_ORCONN_MAPS_H) */
|
||||||
|
@ -11,4 +11,4 @@
|
|||||||
|
|
||||||
extern const struct subsys_fns_t sys_btrack;
|
extern const struct subsys_fns_t sys_btrack;
|
||||||
|
|
||||||
#endif /* defined(TOR_BTRACK_SYS_H) */
|
#endif /* !defined(TOR_BTRACK_SYS_H) */
|
||||||
|
@ -44,4 +44,4 @@ struct control_connection_t {
|
|||||||
char *current_cmd;
|
char *current_cmd;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CONTROL_CONNECTION_ST_H) */
|
||||||
|
@ -58,4 +58,4 @@ STATIC int getinfo_helper_current_time(
|
|||||||
const char **errmsg);
|
const char **errmsg);
|
||||||
#endif /* defined(CONTROL_GETINFO_PRIVATE) */
|
#endif /* defined(CONTROL_GETINFO_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_CONTROL_GETINFO) */
|
#endif /* !defined(TOR_CONTROL_GETINFO_H) */
|
||||||
|
@ -15,4 +15,4 @@
|
|||||||
int list_server_status_v1(smartlist_t *routers, char **router_status_out,
|
int list_server_status_v1(smartlist_t *routers, char **router_status_out,
|
||||||
int for_controller);
|
int for_controller);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_FMT_SERVERSTATUS_H) */
|
||||||
|
@ -11,4 +11,4 @@ int getinfo_helper_geoip(control_connection_t *control_conn,
|
|||||||
const char *question, char **answer,
|
const char *question, char **answer,
|
||||||
const char **errmsg);
|
const char **errmsg);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_GETINFO_GEOIP_H) */
|
||||||
|
@ -29,7 +29,7 @@ authdir_mode_v3(const or_options_t *options)
|
|||||||
|
|
||||||
#define have_module_dirauth() (1)
|
#define have_module_dirauth() (1)
|
||||||
|
|
||||||
#else /* HAVE_MODULE_DIRAUTH */
|
#else /* !(defined(HAVE_MODULE_DIRAUTH)) */
|
||||||
|
|
||||||
#define authdir_mode(options) (((void)(options)),0)
|
#define authdir_mode(options) (((void)(options)),0)
|
||||||
#define authdir_mode_handles_descs(options,purpose) \
|
#define authdir_mode_handles_descs(options,purpose) \
|
||||||
@ -41,6 +41,6 @@ authdir_mode_v3(const or_options_t *options)
|
|||||||
|
|
||||||
#define have_module_dirauth() (0)
|
#define have_module_dirauth() (0)
|
||||||
|
|
||||||
#endif /* HAVE_MODULE_DIRAUTH */
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
|
|
||||||
#endif /* TOR_MODE_H */
|
#endif /* !defined(TOR_DIRAUTH_MODE_H) */
|
||||||
|
@ -9,4 +9,4 @@
|
|||||||
|
|
||||||
void bridgeauth_dump_bridge_status_to_file(time_t now);
|
void bridgeauth_dump_bridge_status_to_file(time_t now);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_DIRAUTH_BRIDGEAUTH_H) */
|
||||||
|
@ -55,4 +55,4 @@ STATIC void dirserv_cache_measured_bw(const measured_bw_line_t *parsed_line,
|
|||||||
STATIC void dirserv_expire_measured_bw_cache(time_t now);
|
STATIC void dirserv_expire_measured_bw_cache(time_t now);
|
||||||
#endif /* defined(BWAUTH_PRIVATE) */
|
#endif /* defined(BWAUTH_PRIVATE) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_BWAUTH_H) */
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
void dirauth_register_periodic_events(void);
|
void dirauth_register_periodic_events(void);
|
||||||
void reschedule_dirvote(const or_options_t *options);
|
void reschedule_dirvote(const or_options_t *options);
|
||||||
|
|
||||||
#else
|
#else /* !(defined(HAVE_MODULE_DIRAUTH)) */
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
reschedule_dirvote(const or_options_t *options)
|
reschedule_dirvote(const or_options_t *options)
|
||||||
@ -20,6 +20,6 @@ reschedule_dirvote(const or_options_t *options)
|
|||||||
(void)options;
|
(void)options;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(DIRVOTE_PERIODIC_H) */
|
||||||
|
@ -9,4 +9,4 @@
|
|||||||
|
|
||||||
extern const struct subsys_fns_t sys_dirauth;
|
extern const struct subsys_fns_t sys_dirauth;
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(DIRAUTH_SYS_H) */
|
||||||
|
@ -128,7 +128,7 @@ struct config_line_t;
|
|||||||
char *format_recommended_version_list(const struct config_line_t *line,
|
char *format_recommended_version_list(const struct config_line_t *line,
|
||||||
int warn);
|
int warn);
|
||||||
|
|
||||||
#else /* HAVE_MODULE_DIRAUTH */
|
#else /* !(defined(HAVE_MODULE_DIRAUTH)) */
|
||||||
|
|
||||||
static inline time_t
|
static inline time_t
|
||||||
dirvote_act(const or_options_t *options, time_t now)
|
dirvote_act(const or_options_t *options, time_t now)
|
||||||
@ -193,7 +193,7 @@ dirvote_add_signatures(const char *detached_signatures_body,
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* HAVE_MODULE_DIRAUTH */
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
|
|
||||||
/* Item access */
|
/* Item access */
|
||||||
MOCK_DECL(const char*, dirvote_get_pending_consensus,
|
MOCK_DECL(const char*, dirvote_get_pending_consensus,
|
||||||
|
@ -19,4 +19,4 @@ void ns_detached_signatures_free_(ns_detached_signatures_t *s);
|
|||||||
#define ns_detached_signatures_free(s) \
|
#define ns_detached_signatures_free(s) \
|
||||||
FREE_AND_NULL(ns_detached_signatures_t, ns_detached_signatures_free_, (s))
|
FREE_AND_NULL(ns_detached_signatures_t, ns_detached_signatures_free_, (s))
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_DSIGS_PARSE_H) */
|
||||||
|
@ -21,4 +21,4 @@ dirserv_read_guardfraction_file_from_str(const char *guardfraction_file_str,
|
|||||||
int dirserv_read_guardfraction_file(const char *fname,
|
int dirserv_read_guardfraction_file(const char *fname,
|
||||||
smartlist_t *vote_routerstatuses);
|
smartlist_t *vote_routerstatuses);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_GUARDFRACTION_H) */
|
||||||
|
@ -18,5 +18,5 @@ struct ns_detached_signatures_t {
|
|||||||
* document_signature_t */
|
* document_signature_t */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(NS_DETACHED_SIGNATURES_ST_H) */
|
||||||
|
|
||||||
|
@ -36,4 +36,4 @@ void dirserv_set_node_flags_from_authoritative_status(node_t *node,
|
|||||||
|
|
||||||
int dirserv_would_reject_router(const routerstatus_t *rs);
|
int dirserv_would_reject_router(const routerstatus_t *rs);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_RECV_UPLOADS_H) */
|
||||||
|
@ -33,4 +33,4 @@ int dirserv_should_launch_reachability_test(const routerinfo_t *ri,
|
|||||||
void dirserv_single_reachability_test(time_t now, routerinfo_t *router);
|
void dirserv_single_reachability_test(time_t now, routerinfo_t *router);
|
||||||
void dirserv_test_reachability(time_t now);
|
void dirserv_test_reachability(time_t now);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_REACHABILITY_H) */
|
||||||
|
@ -24,6 +24,6 @@ validate_recommended_package_line(const char *line)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_RECOMMEND_PKG_H) */
|
||||||
|
@ -110,7 +110,7 @@ int sr_init(int save_to_disk);
|
|||||||
void sr_save_and_cleanup(void);
|
void sr_save_and_cleanup(void);
|
||||||
void sr_act_post_consensus(const networkstatus_t *consensus);
|
void sr_act_post_consensus(const networkstatus_t *consensus);
|
||||||
|
|
||||||
#else /* HAVE_MODULE_DIRAUTH */
|
#else /* !(defined(HAVE_MODULE_DIRAUTH)) */
|
||||||
|
|
||||||
static inline int
|
static inline int
|
||||||
sr_init(int save_to_disk)
|
sr_init(int save_to_disk)
|
||||||
@ -131,7 +131,7 @@ sr_act_post_consensus(const networkstatus_t *consensus)
|
|||||||
(void) consensus;
|
(void) consensus;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* HAVE_MODULE_DIRAUTH */
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
|
|
||||||
/* Public methods used only by dirauth code. */
|
/* Public methods used only by dirauth code. */
|
||||||
|
|
||||||
|
@ -18,5 +18,5 @@ struct vote_microdesc_hash_t {
|
|||||||
char *microdesc_hash_line;
|
char *microdesc_hash_line;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(VOTE_MICRODESC_HASH_ST_H) */
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ void dirauth_set_routerstatus_from_routerinfo(routerstatus_t *rs,
|
|||||||
int listbadexits);
|
int listbadexits);
|
||||||
|
|
||||||
void dirserv_compute_performance_thresholds(digestmap_t *omit_as_sybil);
|
void dirserv_compute_performance_thresholds(digestmap_t *omit_as_sybil);
|
||||||
#endif
|
#endif /* defined(HAVE_MODULE_DIRAUTH) */
|
||||||
|
|
||||||
void dirserv_set_bridges_running(time_t now);
|
void dirserv_set_bridges_running(time_t now);
|
||||||
|
|
||||||
@ -34,6 +34,6 @@ void dirserv_set_bridges_running(time_t now);
|
|||||||
* StaleDesc flag. */
|
* StaleDesc flag. */
|
||||||
#define DESC_IS_STALE_INTERVAL (18*60*60)
|
#define DESC_IS_STALE_INTERVAL (18*60*60)
|
||||||
STATIC void dirserv_set_routerstatus_testing(routerstatus_t *rs);
|
STATIC void dirserv_set_routerstatus_testing(routerstatus_t *rs);
|
||||||
#endif
|
#endif /* defined(VOTEFLAGS_PRIVATE) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_VOTEFLAGS_H) */
|
||||||
|
@ -21,5 +21,5 @@ struct cached_dir_t {
|
|||||||
int refcnt; /**< Reference count for this cached_dir_t. */
|
int refcnt; /**< Reference count for this cached_dir_t. */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(CACHED_DIR_ST_H) */
|
||||||
|
|
||||||
|
@ -525,7 +525,7 @@ consdiffmgr_add_consensus_nulterm(const char *consensus,
|
|||||||
tor_free(ctmp);
|
tor_free(ctmp);
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
#endif
|
#endif /* defined(TOR_UNIT_TESTS) */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Given a buffer containing a networkstatus consensus, and the results of
|
* Given a buffer containing a networkstatus consensus, and the results of
|
||||||
|
@ -38,6 +38,6 @@ STATIC int parse_hs_version_from_post(const char *url, const char *prefix,
|
|||||||
const char **end_pos);
|
const char **end_pos);
|
||||||
|
|
||||||
STATIC unsigned parse_accept_encoding_header(const char *h);
|
STATIC unsigned parse_accept_encoding_header(const char *h);
|
||||||
#endif
|
#endif /* defined(DIRCACHE_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_DIRCACHE_H) */
|
#endif /* !defined(TOR_DIRCACHE_H) */
|
||||||
|
@ -51,4 +51,4 @@ struct dir_server_t {
|
|||||||
**/
|
**/
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(DIR_SERVER_ST_H) */
|
||||||
|
@ -167,6 +167,6 @@ STATIC int handle_response_fetch_consensus(dir_connection_t *conn,
|
|||||||
|
|
||||||
STATIC dirinfo_type_t dir_fetch_type(int dir_purpose, int router_purpose,
|
STATIC dirinfo_type_t dir_fetch_type(int dir_purpose, int router_purpose,
|
||||||
const char *resource);
|
const char *resource);
|
||||||
#endif
|
#endif /* defined(DIRCLIENT_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_DIRCLIENT_H) */
|
#endif /* !defined(TOR_DIRCLIENT_H) */
|
||||||
|
@ -53,6 +53,6 @@ STATIC void next_random_exponential_delay_range(int *low_bound_out,
|
|||||||
/* no more than triple the previous delay */
|
/* no more than triple the previous delay */
|
||||||
#define DIR_TEST_NET_RANDOM_MULTIPLIER (2)
|
#define DIR_TEST_NET_RANDOM_MULTIPLIER (2)
|
||||||
|
|
||||||
#endif
|
#endif /* defined(DLSTATUS_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_DLSTATUS_H) */
|
#endif /* !defined(TOR_DLSTATUS_H) */
|
||||||
|
@ -61,5 +61,5 @@ struct download_status_t {
|
|||||||
* only updated if backoff == 1 */
|
* only updated if backoff == 1 */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(DOWNLOAD_STATUS_ST_H) */
|
||||||
|
|
||||||
|
@ -64,4 +64,4 @@ struct dir_connection_t {
|
|||||||
#endif /* defined(MEASUREMENTS_21206) */
|
#endif /* defined(MEASUREMENTS_21206) */
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(DIR_CONNECTION_ST_H) */
|
||||||
|
@ -20,5 +20,5 @@ struct vote_timing_t {
|
|||||||
int dist_delay;
|
int dist_delay;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(VOTE_TIMING_ST_H) */
|
||||||
|
|
||||||
|
@ -61,5 +61,5 @@ time_t voting_schedule_get_start_of_next_interval(time_t now,
|
|||||||
int offset);
|
int offset);
|
||||||
time_t voting_schedule_get_next_valid_after_time(void);
|
time_t voting_schedule_get_next_valid_after_time(void);
|
||||||
|
|
||||||
#endif /* TOR_VOTING_SCHEDULE_H */
|
#endif /* !defined(TOR_VOTING_SCHEDULE_H) */
|
||||||
|
|
||||||
|
@ -17,4 +17,4 @@ smartlist_t *microdescs_parse_from_string(const char *s, const char *eos,
|
|||||||
saved_location_t where,
|
saved_location_t where,
|
||||||
smartlist_t *invalid_digests_out);
|
smartlist_t *invalid_digests_out);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_MICRODESC_PARSE_H) */
|
||||||
|
@ -42,6 +42,6 @@ STATIC routerstatus_t *routerstatus_parse_entry_from_string(
|
|||||||
vote_routerstatus_t *vote_rs,
|
vote_routerstatus_t *vote_rs,
|
||||||
int consensus_method,
|
int consensus_method,
|
||||||
consensus_flavor_t flav);
|
consensus_flavor_t flav);
|
||||||
#endif
|
#endif /* defined(NS_PARSE_PRIVATE) */
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_NS_PARSE_H) */
|
||||||
|
@ -43,6 +43,6 @@ MOCK_DECL(STATIC int, signed_digest_equals,
|
|||||||
MOCK_DECL(STATIC int, router_compute_hash_final,(char *digest,
|
MOCK_DECL(STATIC int, router_compute_hash_final,(char *digest,
|
||||||
const char *start, size_t len,
|
const char *start, size_t len,
|
||||||
digest_algorithm_t alg));
|
digest_algorithm_t alg));
|
||||||
#endif
|
#endif /* defined(SIGCOMMON_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_SIGCOMMON_H) */
|
#endif /* !defined(TOR_SIGCOMMON_H) */
|
||||||
|
@ -20,4 +20,4 @@ int router_append_dirobj_signature(char *buf, size_t buf_len,
|
|||||||
const char *digest,
|
const char *digest,
|
||||||
size_t digest_len,
|
size_t digest_len,
|
||||||
crypto_pk_t *private_key);
|
crypto_pk_t *private_key);
|
||||||
#endif
|
#endif /* !defined(TOR_SIGNING_H) */
|
||||||
|
@ -51,6 +51,6 @@ EXTERN(struct smartlist_t *, descs_dumped)
|
|||||||
MOCK_DECL(STATIC dumped_desc_t *, dump_desc_populate_one_file,
|
MOCK_DECL(STATIC dumped_desc_t *, dump_desc_populate_one_file,
|
||||||
(const char *dirname, const char *f));
|
(const char *dirname, const char *f));
|
||||||
STATIC void dump_desc_populate_fifo_from_directory(const char *dirname);
|
STATIC void dump_desc_populate_fifo_from_directory(const char *dirname);
|
||||||
#endif
|
#endif /* defined(UNPARSEABLE_PRIVATE) */
|
||||||
|
|
||||||
#endif /* !defined(TOR_UNPARSEABLE_H) */
|
#endif /* !defined(TOR_UNPARSEABLE_H) */
|
||||||
|
@ -57,7 +57,7 @@ hibernating, phase 2:
|
|||||||
* Coverity. Here's a kludge to unconfuse it.
|
* Coverity. Here's a kludge to unconfuse it.
|
||||||
*/
|
*/
|
||||||
# define __INCLUDE_LEVEL__ 2
|
# define __INCLUDE_LEVEL__ 2
|
||||||
# endif /* defined(__COVERITY__) && !defined(__INCLUDE_LEVEL__) */
|
#endif /* defined(__COVERITY__) && !defined(__INCLUDE_LEVEL__) */
|
||||||
#include <systemd/sd-daemon.h>
|
#include <systemd/sd-daemon.h>
|
||||||
#endif /* defined(HAVE_SYSTEMD) */
|
#endif /* defined(HAVE_SYSTEMD) */
|
||||||
|
|
||||||
@ -893,7 +893,7 @@ hibernate_begin(hibernate_state_t new_state, time_t now)
|
|||||||
*/
|
*/
|
||||||
sd_notifyf(0, "EXTEND_TIMEOUT_USEC=%" PRIu64,
|
sd_notifyf(0, "EXTEND_TIMEOUT_USEC=%" PRIu64,
|
||||||
((uint64_t)(options->ShutdownWaitLength) + 30) * TOR_USEC_PER_SEC);
|
((uint64_t)(options->ShutdownWaitLength) + 30) * TOR_USEC_PER_SEC);
|
||||||
#endif
|
#endif /* defined(HAVE_SYSTEMD) */
|
||||||
} else { /* soft limit reached */
|
} else { /* soft limit reached */
|
||||||
hibernate_end_time = interval_end_time;
|
hibernate_end_time = interval_end_time;
|
||||||
}
|
}
|
||||||
|
@ -361,7 +361,7 @@ STATIC hs_service_t *get_first_service(void);
|
|||||||
STATIC hs_service_intro_point_t *service_intro_point_find_by_ident(
|
STATIC hs_service_intro_point_t *service_intro_point_find_by_ident(
|
||||||
const hs_service_t *service,
|
const hs_service_t *service,
|
||||||
const hs_ident_circuit_t *ident);
|
const hs_ident_circuit_t *ident);
|
||||||
#endif
|
#endif /* defined(TOR_UNIT_TESTS) */
|
||||||
|
|
||||||
/* Service accessors. */
|
/* Service accessors. */
|
||||||
STATIC hs_service_t *find_service(hs_service_ht *map,
|
STATIC hs_service_t *find_service(hs_service_ht *map,
|
||||||
|
@ -15,4 +15,4 @@ uint32_t hs_stats_get_n_introduce2_v2_cells(void);
|
|||||||
void hs_stats_note_service_rendezvous_launch(void);
|
void hs_stats_note_service_rendezvous_launch(void);
|
||||||
uint32_t hs_stats_get_n_rendezvous_launches(void);
|
uint32_t hs_stats_get_n_rendezvous_launches(void);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_HS_STATS_H) */
|
||||||
|
@ -20,5 +20,5 @@ struct hsdir_index_t {
|
|||||||
uint8_t store_second[DIGEST256_LEN];
|
uint8_t store_second[DIGEST256_LEN];
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(HSDIR_INDEX_ST_H) */
|
||||||
|
|
||||||
|
@ -44,5 +44,5 @@ time_t get_start_time_of_current_round(void);
|
|||||||
|
|
||||||
#endif /* TOR_UNIT_TESTS */
|
#endif /* TOR_UNIT_TESTS */
|
||||||
|
|
||||||
#endif /* TOR_SHARED_RANDOM_CLIENT_H */
|
#endif /* !defined(TOR_SHARED_RANDOM_CLIENT_H) */
|
||||||
|
|
||||||
|
@ -52,4 +52,4 @@ int read_encrypted_secret_key(ed25519_secret_key_t *out,
|
|||||||
int write_encrypted_secret_key(const ed25519_secret_key_t *out,
|
int write_encrypted_secret_key(const ed25519_secret_key_t *out,
|
||||||
const char *fname);
|
const char *fname);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_LOADKEY_H) */
|
||||||
|
@ -57,4 +57,4 @@ MOCK_DECL(download_status_t *, download_status_for_authority_id_and_sk,
|
|||||||
|
|
||||||
void authcert_free_all(void);
|
void authcert_free_all(void);
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(TOR_AUTHCERT_H) */
|
||||||
|
@ -28,5 +28,5 @@ struct authority_cert_t {
|
|||||||
uint16_t dir_port;
|
uint16_t dir_port;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif /* !defined(AUTHORITY_CERT_ST_H) */
|
||||||
|
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user