[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] backport: Stop dnsworkers from triggering an assert failure...
- To: or-cvs@freehaven.net
- Subject: [or-cvs] backport: Stop dnsworkers from triggering an assert failure...
- From: arma@seul.org (Roger Dingledine)
- Date: Thu, 12 Aug 2004 02:27:14 -0400 (EDT)
- Delivered-to: archiver@seul.org
- Delivered-to: or-cvs-outgoing@seul.org
- Delivered-to: or-cvs@seul.org
- Delivery-date: Thu, 12 Aug 2004 02:27:49 -0400
- Reply-to: or-dev@freehaven.net
- Sender: owner-or-cvs@freehaven.net
Update of /home2/or/cvsroot/src/or
In directory moria.mit.edu:/home2/arma/work/onion/0072/src/or
Modified Files:
Tag: tor-0_0_7-patches
dns.c
Log Message:
backport: Stop dnsworkers from triggering an assert failure when you
ask them to resolve the host "".
Index: dns.c
===================================================================
RCS file: /home2/or/cvsroot/src/or/dns.c,v
retrieving revision 1.99.2.1
retrieving revision 1.99.2.2
diff -u -d -r1.99.2.1 -r1.99.2.2
--- dns.c 4 Jul 2004 04:53:32 -0000 1.99.2.1
+++ dns.c 12 Aug 2004 06:27:11 -0000 1.99.2.2
@@ -599,9 +599,8 @@
log_fn(LOG_INFO,"dnsworker exiting because tor process died.");
spawn_exit();
}
- tor_assert(address_len > 0);
- if(read_all(fd, address, address_len, 1) != address_len) {
+ if(address_len && read_all(fd, address, address_len, 1) != address_len) {
log_fn(LOG_ERR,"read hostname failed. Child exiting.");
spawn_exit();
}