aboutsummaryrefslogtreecommitdiff
path: root/src/or/circuitlist.c
diff options
context:
space:
mode:
authorRoger Dingledine <arma@torproject.org>2005-03-22 00:42:38 +0000
committerRoger Dingledine <arma@torproject.org>2005-03-22 00:42:38 +0000
commit35953edae073e69efe06f4ea313066b514b772a0 (patch)
tree3f89981b90370e5c4c727e3b86905813871828d9 /src/or/circuitlist.c
parent5d5b12ce750e60041f7654449129fe268ed76a2e (diff)
downloadtor-35953edae073e69efe06f4ea313066b514b772a0.tar
tor-35953edae073e69efe06f4ea313066b514b772a0.tar.gz
Implement controller's "extendcircuit" directive.
Also refactor circuit building so we plan the whole path ahead of time. svn:r3797
Diffstat (limited to 'src/or/circuitlist.c')
-rw-r--r--src/or/circuitlist.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/or/circuitlist.c b/src/or/circuitlist.c
index 2c5c300e3..a25c874fd 100644
--- a/src/or/circuitlist.c
+++ b/src/or/circuitlist.c
@@ -76,7 +76,8 @@ void circuit_close_all_marked(void)
*/
circuit_t *circuit_new(uint16_t p_circ_id, connection_t *p_conn) {
circuit_t *circ;
- static uint32_t n_circuits_allocated = 0;
+ static uint32_t n_circuits_allocated = 1;
+ /* never zero, since a global ID of 0 treated specially by the controller */
circ = tor_malloc_zero(sizeof(circuit_t));
circ->magic = CIRCUIT_MAGIC;