From 1da454a42d850ec50612416e3d1d5ac1c43b517b Mon Sep 17 00:00:00 2001 From: Roger Dingledine Date: Mon, 28 Nov 2005 02:52:17 +0000 Subject: [PATCH] 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 --- src/or/circuitlist.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/or/circuitlist.c b/src/or/circuitlist.c index 22f048f2de..78cda53343 100644 --- a/src/or/circuitlist.c +++ b/src/or/circuitlist.c @@ -443,7 +443,7 @@ circuit_get_all_on_orconn(connection_t *conn) for (circ=global_circuitlist;circ;circ = circ->next) { if (!circ->marked_for_close && (circ->p_conn == conn || circ->n_conn == conn)) - smartlist_add(res, conn); + smartlist_add(res, circ); } return res; }