Skip to content
Snippets Groups Projects
Commit 612b801e authored by David Goulet's avatar David Goulet :panda_face:
Browse files

conflux: Don't process a closed circuit on get packaged window

parent 6ebf4360
No related branches found
No related tags found
No related merge requests found
o Minor bugfixes (conflux):
- Make sure we don't process a closed circuit when packaging data. This lead
to a non fatal BUG() spamming logs. Fixes bug 40908; bugfix on
0.4.8.1-alpha.
...@@ -33,6 +33,13 @@ int ...@@ -33,6 +33,13 @@ int
circuit_get_package_window(circuit_t *circ, circuit_get_package_window(circuit_t *circ,
const crypt_path_t *cpath) const crypt_path_t *cpath)
{ {
/* We believe it is possible to get a closed circuit related to the
* on_circuit pointer of a connection not being nullified before ending up
* here. Else, this can lead to loud bug like experienced in #40908. */
if (circ->marked_for_close) {
return 0;
}
if (circ->conflux) { if (circ->conflux) {
if (CIRCUIT_IS_ORIGIN(circ)) { if (CIRCUIT_IS_ORIGIN(circ)) {
tor_assert_nonfatal(circ->purpose == tor_assert_nonfatal(circ->purpose ==
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment