[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[or-cvs] More DNS fixes. Send meaningful TTLs back to the client when
Update of /home/or/cvsroot/tor/src/common
In directory moria:/tmp/cvs-serv30284/src/common
Modified Files:
compat.c
Log Message:
More DNS fixes. Send meaningful TTLs back to the client when
possible. Cache at the server side independently from the TTL, to
prevent attackers from probing the server to see who has been asking
for what hostnames. (Hi, Dan Kaminski!)
Also, clean some whitespace.
Index: compat.c
===================================================================
RCS file: /home/or/cvsroot/tor/src/common/compat.c,v
retrieving revision 1.87
retrieving revision 1.88
diff -u -p -d -r1.87 -r1.88
--- compat.c 28 May 2006 16:54:39 -0000 1.87
+++ compat.c 3 Jun 2006 21:41:14 -0000 1.88
@@ -131,7 +131,7 @@ tor_mmap_file(const char *filename, size
*size += (page_size + (page_size-(*size%page_size)));
string = mmap(0, *size, PROT_READ, MAP_PRIVATE, fd, 0);
- if(string == MAP_FAILED) {
+ if (string == MAP_FAILED) {
log_warn(LD_FS,"Could not mmap file \"%s\": %s", filename,
strerror(errno));
return NULL;