]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Only connection_dns_remove resolving exit connections
authorNick Mathewson <nickm@torproject.org>
Wed, 2 Jun 2004 18:12:49 +0000 (18:12 +0000)
committerNick Mathewson <nickm@torproject.org>
Wed, 2 Jun 2004 18:12:49 +0000 (18:12 +0000)
svn:r1934

src/or/dns.c

index 964230f722de25723549991a7f02426f2331f3d9..3809fe7689a7cd4081d5896838f8610d19d3d8a3 100644 (file)
@@ -264,6 +264,9 @@ void connection_dns_remove(connection_t *conn)
   struct cached_resolve search;
   struct cached_resolve *resolve;
 
+  tor_assert(conn->type == CONN_TYPE_EXIT);
+  tor_assert(conn->state == EXIT_CONN_STATE_RESOLVING);
+
   strncpy(search.address, conn->address, MAX_ADDRESSLEN);
   search.address[MAX_ADDRESSLEN-1] = 0;