diff options
author | George Kadianakis <desnacked@riseup.net> | 2019-04-09 17:57:04 +0300 |
---|---|---|
committer | George Kadianakis <desnacked@riseup.net> | 2019-05-03 18:15:26 +0300 |
commit | 0ed5c6edf9c905276d462ed2402568216ecb1dee (patch) | |
tree | 63c2c46dd962acbe517acfa1b2147114ced74549 /src/core/or/crypt_path.h | |
parent | 58fbbc1409f65bbb65c9da03a035a5767820146b (diff) | |
download | tor-0ed5c6edf9c905276d462ed2402568216ecb1dee.tar.gz tor-0ed5c6edf9c905276d462ed2402568216ecb1dee.zip |
Hiding crypt_path_t: Move some more crypt_path-specific functions.
- Move test-only cpath_get_n_hops() to crypt_path.c.
- Move onion_next_hop_in_cpath() and rename to cpath_get_next_non_open_hop().
The latter function was directly accessing cpath->state, and it's a first step
at hiding ->state.
Diffstat (limited to 'src/core/or/crypt_path.h')
-rw-r--r-- | src/core/or/crypt_path.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/core/or/crypt_path.h b/src/core/or/crypt_path.h index 4a0117360e..ed59037760 100644 --- a/src/core/or/crypt_path.h +++ b/src/core/or/crypt_path.h @@ -32,4 +32,10 @@ cpath_get_incoming_digest(const crypt_path_t *cpath); void cpath_set_cell_forward_digest(crypt_path_t *cpath, cell_t *cell); +crypt_path_t *cpath_get_next_non_open_hop(crypt_path_t *cpath); + +#if defined(TOR_UNIT_TESTS) +unsigned int cpath_get_n_hops(crypt_path_t **head_ptr); +#endif /* defined(TOR_UNIT_TESTS) */ + #endif |