mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-09-21 05:26:20 +02:00
send truncates AP-ward in a circuit, not destroys
svn:r313
This commit is contained in:
parent
d3292e484a
commit
030564e95d
@ -204,11 +204,15 @@ void command_process_destroy_cell(cell_t *cell, connection_t *conn) {
|
|||||||
onion_pending_remove(circ);
|
onion_pending_remove(circ);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(cell->aci == circ->p_aci) /* the destroy came from behind */
|
if(cell->aci == circ->p_aci || circ->cpath) {
|
||||||
|
/* either the destroy came from behind, or we're the AP */
|
||||||
circ->p_conn = NULL;
|
circ->p_conn = NULL;
|
||||||
if(cell->aci == circ->n_aci) /* the destroy came from ahead */
|
|
||||||
circ->n_conn = NULL;
|
|
||||||
circuit_close(circ);
|
circuit_close(circ);
|
||||||
|
} else { /* the destroy came from ahead */
|
||||||
|
circ->n_conn = NULL;
|
||||||
|
log(LOG_DEBUG, "command_process_destroy_cell(): Delivering 'truncated' back.");
|
||||||
|
connection_edge_send_command(NULL, circ, RELAY_COMMAND_TRUNCATED);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user