mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-11 05:33:47 +01:00
when returning a list of circuits, don't return a list of the same
conn over and over. that's really bad for memory. svn:r5463
This commit is contained in:
parent
f94f4c1686
commit
1da454a42d
@ -443,7 +443,7 @@ circuit_get_all_on_orconn(connection_t *conn)
|
|||||||
for (circ=global_circuitlist;circ;circ = circ->next) {
|
for (circ=global_circuitlist;circ;circ = circ->next) {
|
||||||
if (!circ->marked_for_close &&
|
if (!circ->marked_for_close &&
|
||||||
(circ->p_conn == conn || circ->n_conn == conn))
|
(circ->p_conn == conn || circ->n_conn == conn))
|
||||||
smartlist_add(res, conn);
|
smartlist_add(res, circ);
|
||||||
}
|
}
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user