[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[or-cvs] [tor/maint-0.2.1] Have eventdns set the "truncated" bit correctly.



Author: Nick Mathewson <nickm@xxxxxxxxxxxxxx>
Date: Tue, 30 Jun 2009 10:05:42 -0400
Subject: Have eventdns set the "truncated" bit correctly.
Commit: 7ce767181f42879d48737ba69c4ce99963d76d9f

Fixed bug 1022; This isn't actually a live bug in Tor, since in Tor
we never generate large DNS replies.
---
 src/or/eventdns.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/or/eventdns.c b/src/or/eventdns.c
index 4464148..4ae17a4 100644
--- a/src/or/eventdns.c
+++ b/src/or/eventdns.c
@@ -1842,7 +1842,7 @@ evdns_server_request_format_response(struct server_request *req, int err)
 	if (j > 512) {
 overflow:
 		j = 512;
-		buf[3] |= 0x02; /* set the truncated bit. */
+		buf[2] |= 0x02; /* set the truncated bit. */
 	}
 
 	req->response_len = (size_t)j;
-- 
1.5.6.5