mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-30 15:43:32 +01:00
Bug 40834: Remove assert and add logs to track no-leg case
This commit is contained in:
parent
72164740a2
commit
a56434a82b
@ -467,8 +467,12 @@ conflux_decide_circ_for_send(conflux_t *cfx,
|
||||
* so these commands arrive in-order. */
|
||||
if (!new_circ && relay_command != RELAY_COMMAND_DATA) {
|
||||
/* Curr leg should be set, because conflux_decide_next_circ() should
|
||||
* have set it earlier. */
|
||||
tor_assert(cfx->curr_leg);
|
||||
* have set it earlier. No BUG() here because the only caller BUG()s. */
|
||||
if (!cfx->curr_leg) {
|
||||
log_warn(LD_BUG, "No current leg for conflux with relay command %d",
|
||||
relay_command);
|
||||
return NULL;
|
||||
}
|
||||
return cfx->curr_leg->circ;
|
||||
}
|
||||
|
||||
|
@ -639,7 +639,8 @@ relay_send_command_from_edge_,(streamid_t stream_id, circuit_t *orig_circ,
|
||||
circ = conflux_decide_circ_for_send(orig_circ->conflux, orig_circ,
|
||||
relay_command);
|
||||
if (BUG(!circ)) {
|
||||
log_warn(LD_BUG, "No circuit to send on for conflux");
|
||||
log_warn(LD_BUG, "No circuit to send for conflux for relay command %d, "
|
||||
"called from %s:%d", relay_command, filename, lineno);
|
||||
circ = orig_circ;
|
||||
} else {
|
||||
/* Conflux circuits always send multiplexed relay commands to
|
||||
|
Loading…
Reference in New Issue
Block a user