r15520@tombo: nickm | 2007-12-16 13:54:22 -0500

Fix for bug 1846282: accept as well-formed DNS replies with questions but no answers. [Backport to 1.4]


svn:r596
This commit is contained in:
Nick Mathewson 2007-12-16 18:55:47 +00:00
parent 5bb67a80fa
commit c7bc1f10cf
2 changed files with 3 additions and 2 deletions

View File

@ -17,7 +17,8 @@ Changes in current version:
o move EV_PERSIST handling out of the event backends
o support for 32-bit tag numbers in rpc structures; this is wire compatible, but changes the API slightly.
o prefix {encode,decode}_tag functions with evtag to avoid collisions
o Correctly handle DNS replies with no answers set (Fixes bug 1846282)
Changes in 1.4.0-beta:
o allow \r or \n individually to separate HTTP headers instead of the standard "\r\n"; from Charles Kerr.

View File

@ -867,7 +867,7 @@ reply_parse(u8 *packet, int length) {
*/
SKIP_NAME;
j += 4;
if (j >= length) goto err;
if (j > length) goto err;
}
/* now we have the answer section which looks like