Skip to content

Commit 7a52469

Browse files
stek29edsiper
authored andcommitted
network: enable EDNS for DNS queries to support large responses
Always set ARES_FLAG_EDNS to handle DNS responses >512 bytes. Fixes: #10588 Signed-off-by: Viktor Oreshkin <[email protected]>
1 parent c9f65ca commit 7a52469

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/flb_network.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1092,8 +1092,9 @@ static struct flb_dns_lookup_context *flb_net_dns_lookup_context_create(
10921092

10931093
optmask = ARES_OPT_FLAGS;
10941094

1095+
opts.flags = ARES_FLAG_EDNS;
10951096
if (dns_mode == FLB_DNS_USE_TCP) {
1096-
opts.flags = ARES_FLAG_USEVC;
1097+
opts.flags |= ARES_FLAG_USEVC;
10971098
}
10981099

10991100
*result = ares_init_options((ares_channel *) &lookup_context->ares_channel,

0 commit comments

Comments
 (0)