Commit 9b0e404e authored by Brian Wellington's avatar Brian Wellington
Browse files

666. [bug] If a request is longer than 512 bytes, send it using

                        TCP.
parent fff07c10
666. [bug] If a request is longer than 512 bytes, send it using
TCP.
665. [bug] Signed responses were not sent when the size of the
TSIG + question exceeded the maximum message size.
[RT #628]
......
......@@ -15,7 +15,7 @@
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dighost.c,v 1.176 2001/01/08 19:50:32 bwelling Exp $ */
/* $Id: dighost.c,v 1.177 2001/01/08 20:50:04 bwelling Exp $ */
/*
* Notice to programmers: Do not use this code as an example of how to
......@@ -1522,6 +1522,12 @@ setup_lookup(dig_lookup_t *lookup) {
check_result(result, "dns_message_renderend");
debug("done rendering");
/*
* Force TCP mode if the request is larger than 512 bytes.
*/
if (isc_buffer_usedlength(&lookup->sendbuf) > 512)
lookup->tcp_mode = ISC_TRUE;
lookup->pending = ISC_FALSE;
for (serv = ISC_LIST_HEAD(lookup->my_server_list);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment