r8776@Kushana: nickm | 2006-09-11 22:49:53 -0400

Avoid crash when telling controller stream-status and a stream is detached.  Fixes bug 334. Backport candidate.


svn:r8370
This commit is contained in:
Nick Mathewson 2006-09-12 02:50:14 +00:00
parent 8170f1e037
commit 1852f503cf

View File

@ -1453,7 +1453,7 @@ handle_getinfo_helper(const char *question, char **answer)
continue;
}
circ = circuit_get_by_edge_conn(conn);
if (CIRCUIT_IS_ORIGIN(circ))
if (circ && CIRCUIT_IS_ORIGIN(circ))
origin_circ = TO_ORIGIN_CIRCUIT(circ);
write_stream_target_to_buf(conn, buf, sizeof(buf));
slen = strlen(buf)+strlen(state)+32;