summaryrefslogtreecommitdiff
path: root/src/or/rendservice.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-04-16 10:38:55 -0400
committerNick Mathewson <nickm@torproject.org>2018-04-22 19:42:26 -0400
commit948dd2c79ea9ca1fd06c13f275515a1745c46986 (patch)
treeafc311f00bca225b6745b4778a73f38d741c6eb9 /src/or/rendservice.c
parent22845df2a7503ed73ed325c3a98916f289918caa (diff)
downloadtor-948dd2c79ea9ca1fd06c13f275515a1745c46986.tar.gz
tor-948dd2c79ea9ca1fd06c13f275515a1745c46986.zip
Check for "the right descriptor", not just "any descriptor".
This patch adds a new node_has_preferred_descriptor() function, and replaces most users of node_has_descriptor() with it. That's an important change, since as of d1874b433953f64 (our fix for #25213), we are willing to say that a node has _some_ descriptor, but not the _right_ descriptor for a particular use case. Part of a fix for 25691 and 25692.
Diffstat (limited to 'src/or/rendservice.c')
-rw-r--r--src/or/rendservice.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/rendservice.c b/src/or/rendservice.c
index cc22429777..1a93c36433 100644
--- a/src/or/rendservice.c
+++ b/src/or/rendservice.c
@@ -3596,7 +3596,7 @@ directory_post_to_hs_dir(rend_service_descriptor_t *renddesc,
/* Don't upload descriptor if we succeeded in doing so last time. */
continue;
node = node_get_by_id(hs_dir->identity_digest);
- if (!node || !node_has_descriptor(node)) {
+ if (!node || !node_has_preferred_descriptor(node,0)) {
log_info(LD_REND, "Not launching upload for for v2 descriptor to "
"hidden service directory %s; we don't have its "
"router descriptor. Queuing for later upload.",