aboutsummaryrefslogtreecommitdiff
path: root/src/test/test_hs_common.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-04-16 11:51:02 -0400
committerNick Mathewson <nickm@torproject.org>2018-04-22 19:43:07 -0400
commit47163780c3682d881ad6e8044320a57fce439ea1 (patch)
treedcc67e42a02501a6f07d5e6090b610927eb535ad /src/test/test_hs_common.c
parent0f3d73a2d0ef22d51183768308887d0271ef20f0 (diff)
downloadtor-47163780c3682d881ad6e8044320a57fce439ea1.tar.gz
tor-47163780c3682d881ad6e8044320a57fce439ea1.zip
Rename node_has_descriptor() to node_has_any_descriptor()
Changing the name of this function should help keep us from misusing it when node_has_preferred_descriptor() would be more appropriate.
Diffstat (limited to 'src/test/test_hs_common.c')
-rw-r--r--src/test/test_hs_common.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/test/test_hs_common.c b/src/test/test_hs_common.c
index 8c273c9639..17ba11ca7d 100644
--- a/src/test/test_hs_common.c
+++ b/src/test/test_hs_common.c
@@ -305,7 +305,8 @@ helper_add_hsdir_to_networkstatus(networkstatus_t *ns,
node_t *node = node_get_mutable_by_id(ri->cache_info.identity_digest);
tt_assert(node);
node->rs = rs;
- /* We need this to exist for node_has_descriptor() to return true. */
+ /* We need this to exist for node_has_preferred_descriptor() to return
+ * true. */
node->md = tor_malloc_zero(sizeof(microdesc_t));
/* Do this now the nodelist_set_routerinfo() function needs a "rs" to set
* the indexes which it doesn't have when it is called. */