aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlexander Færøy <ahf@torproject.org>2024-02-28 16:52:56 +0000
committerAlexander Færøy <ahf@torproject.org>2024-02-28 16:52:56 +0000
commit72ac1de514fb3f7ee9fc301cd20498c92c29a360 (patch)
tree9b043257075262ee4221b23dfa7ffe8246a11a0f /src
parentb0b943a1613e2f9b421a663a3bf84fb4bbdbadc5 (diff)
parent6b665f25e2b9d2a51fac4968d88e8ae45d4d71d7 (diff)
downloadtor-72ac1de514fb3f7ee9fc301cd20498c92c29a360.tar.gz
tor-72ac1de514fb3f7ee9fc301cd20498c92c29a360.zip
Merge branch 'maint-0.4.8'
Diffstat (limited to 'src')
-rw-r--r--src/feature/dirclient/dirclient.c7
-rw-r--r--src/test/test_dir.c2
2 files changed, 7 insertions, 2 deletions
diff --git a/src/feature/dirclient/dirclient.c b/src/feature/dirclient/dirclient.c
index 84eefdd90b..9aa3164a65 100644
--- a/src/feature/dirclient/dirclient.c
+++ b/src/feature/dirclient/dirclient.c
@@ -101,7 +101,7 @@ dir_conn_purpose_to_string(int purpose)
case DIR_PURPOSE_UPLOAD_DIR:
return "server descriptor upload";
case DIR_PURPOSE_UPLOAD_VOTE:
- return "server vote upload";
+ return "consensus vote upload";
case DIR_PURPOSE_UPLOAD_SIGNATURES:
return "consensus signature upload";
case DIR_PURPOSE_FETCH_SERVERDESC:
@@ -763,6 +763,11 @@ connection_dir_client_request_failed(dir_connection_t *conn)
"directory server at %s; will retry",
connection_describe_peer(TO_CONN(conn)));
connection_dir_download_routerdesc_failed(conn);
+ } else if (conn->base_.purpose == DIR_PURPOSE_UPLOAD_VOTE ||
+ conn->base_.purpose == DIR_PURPOSE_UPLOAD_SIGNATURES) {
+ log_warn(LD_DIR, "Failed to post %s to %s.",
+ dir_conn_purpose_to_string(conn->base_.purpose),
+ connection_describe_peer(TO_CONN(conn)));
}
}
diff --git a/src/test/test_dir.c b/src/test/test_dir.c
index 1811098440..a86638f8c9 100644
--- a/src/test/test_dir.c
+++ b/src/test/test_dir.c
@@ -5264,7 +5264,7 @@ test_dir_conn_purpose_to_string(void *data)
tt_str_op(dir_conn_purpose_to_string(purpose), OP_EQ, expected);
EXPECT_CONN_PURPOSE(DIR_PURPOSE_UPLOAD_DIR, "server descriptor upload");
- EXPECT_CONN_PURPOSE(DIR_PURPOSE_UPLOAD_VOTE, "server vote upload");
+ EXPECT_CONN_PURPOSE(DIR_PURPOSE_UPLOAD_VOTE, "consensus vote upload");
EXPECT_CONN_PURPOSE(DIR_PURPOSE_UPLOAD_SIGNATURES,
"consensus signature upload");
EXPECT_CONN_PURPOSE(DIR_PURPOSE_FETCH_SERVERDESC, "server descriptor fetch");