aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/or/circuituse.c4
-rw-r--r--src/or/router.c11
-rw-r--r--src/rust/Cargo.toml10
3 files changed, 19 insertions, 6 deletions
diff --git a/src/or/circuituse.c b/src/or/circuituse.c
index 8e007ce920..03f2ae52cf 100644
--- a/src/or/circuituse.c
+++ b/src/or/circuituse.c
@@ -1560,10 +1560,14 @@ circuit_expire_old_circuits_serverside(time_t now)
or_circ = TO_OR_CIRCUIT(circ);
/* If the circuit has been idle for too long, and there are no streams
* on it, and it ends here, and it used a create_fast, mark it for close.
+ *
+ * Also if there is a rend_splice on it, it's a single onion service
+ * circuit and we should not close it.
*/
if (or_circ->p_chan && channel_is_client(or_circ->p_chan) &&
!circ->n_chan &&
!or_circ->n_streams && !or_circ->resolving_streams &&
+ !or_circ->rend_splice &&
channel_when_last_xmit(or_circ->p_chan) <= cutoff) {
log_info(LD_CIRC, "Closing circ_id %u (empty %d secs ago)",
(unsigned)or_circ->p_circ_id,
diff --git a/src/or/router.c b/src/or/router.c
index 03959e907d..2f7d8349f9 100644
--- a/src/or/router.c
+++ b/src/or/router.c
@@ -3421,12 +3421,11 @@ extrainfo_dump_to_string(char **s_out, extrainfo_t *extrainfo,
"conn-bi-direct", now, &contents) > 0) {
smartlist_add(chunks, contents);
}
- }
-
- if (options->PaddingStatistics) {
- contents = rep_hist_get_padding_count_lines();
- if (contents)
- smartlist_add(chunks, contents);
+ if (options->PaddingStatistics) {
+ contents = rep_hist_get_padding_count_lines();
+ if (contents)
+ smartlist_add(chunks, contents);
+ }
}
/* Add information about the pluggable transports we support. */
diff --git a/src/rust/Cargo.toml b/src/rust/Cargo.toml
index c3e44d2a79..de8693ea33 100644
--- a/src/rust/Cargo.toml
+++ b/src/rust/Cargo.toml
@@ -10,7 +10,17 @@ members = [
"tor_util",
]
+# Can remove panic="abort" when this issue is fixed:
+# https://github.com/rust-lang/rust/issues/52652
+[profile.dev]
+panic = "abort"
+
[profile.release]
debug = true
panic = "abort"
+[profile.test]
+panic = "abort"
+
+[profile.bench]
+panic = "abort"