diff options
author | Nick Mathewson <nickm@torproject.org> | 2005-09-12 03:32:30 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2005-09-12 03:32:30 +0000 |
commit | 63dfe2447ee4f283988c81c9025303503201d690 (patch) | |
tree | ec4daaa73a523703c6a83fd4070c7e732b7455dc | |
parent | 24bfac635d6536eb7ad97da71256803a6e99cbe1 (diff) | |
download | tor-63dfe2447ee4f283988c81c9025303503201d690.tar.gz tor-63dfe2447ee4f283988c81c9025303503201d690.zip |
Fix bug found by "ca": looking up a non-existent stream for a v1 control connection would cause a segfault. (No backport needed since 0.1.0 had only v0 connections.)
svn:r5001
-rw-r--r-- | src/or/control.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/control.c b/src/or/control.c index a1dd0532fe..2e19069b7c 100644 --- a/src/or/control.c +++ b/src/or/control.c @@ -599,7 +599,7 @@ get_stream(const char *id) if (!ok) return NULL; conn = connection_get_by_global_id(n_id); - if (conn->type != CONN_TYPE_AP) + if (!conn || conn->type != CONN_TYPE_AP) return NULL; return conn; } |