diff options
author | Reinaldo de Souza Jr <juniorz@gmail.com> | 2015-09-07 14:04:51 -0500 |
---|---|---|
committer | Reinaldo de Souza Jr <juniorz@gmail.com> | 2015-09-15 11:08:25 -0500 |
commit | d5e860e3dca8cd9159e17555541262c828d05976 (patch) | |
tree | 444e0277494dc4ec6c97591782cd653fa1b6a468 /src/or/directory.h | |
parent | a444b11323799536b4cd7902e29f711b0806293a (diff) | |
download | tor-d5e860e3dca8cd9159e17555541262c828d05976.tar.gz tor-d5e860e3dca8cd9159e17555541262c828d05976.zip |
Add tests for src/or/directory.c
Diffstat (limited to 'src/or/directory.h')
-rw-r--r-- | src/or/directory.h | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/src/or/directory.h b/src/or/directory.h index 4899eb5c8c..d859df3061 100644 --- a/src/or/directory.h +++ b/src/or/directory.h @@ -37,14 +37,16 @@ typedef enum { DIRIND_ANON_DIRPORT, } dir_indirection_t; -void directory_initiate_command_routerstatus(const routerstatus_t *status, - uint8_t dir_purpose, - uint8_t router_purpose, - dir_indirection_t indirection, - const char *resource, - const char *payload, - size_t payload_len, - time_t if_modified_since); +MOCK_DECL(void, directory_initiate_command_routerstatus, + (const routerstatus_t *status, + uint8_t dir_purpose, + uint8_t router_purpose, + dir_indirection_t indirection, + const char *resource, + const char *payload, + size_t payload_len, + time_t if_modified_since)); + void directory_initiate_command_routerstatus_rend(const routerstatus_t *status, uint8_t dir_purpose, uint8_t router_purpose, @@ -127,6 +129,12 @@ STATIC int purpose_needs_anonymity(uint8_t dir_purpose, uint8_t router_purpose); STATIC dirinfo_type_t dir_fetch_type(int dir_purpose, int router_purpose, const char *resource); +STATIC char* authdir_type_to_string(dirinfo_type_t auth); +STATIC const char * dir_conn_purpose_to_string(int purpose); +STATIC int should_use_directory_guards(const or_options_t *options); +STATIC zlib_compression_level_t choose_compression_level(ssize_t n_bytes); +STATIC const smartlist_t * find_dl_schedule_and_len(download_status_t *dls, + int server); #endif #endif |