Skip to content

Commit

Permalink
fix: remove retries
Browse files Browse the repository at this point in the history
following comments in the PR, the preferred option
is to remove the ineffective retries option and the mask
that would have caused it to have any effect.

The resulting code should behave exactly as before, since
the mask was required for the original retries option to work,
and it has never been set; so no additonal tests are supplied.

Signed-off-by: bazzargh <[email protected]>
  • Loading branch information
bazzargh authored Apr 12, 2024
1 parent 8d22ee4 commit a2fc10e
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/flb_network.c
Original file line number Diff line number Diff line change
Expand Up @@ -996,12 +996,9 @@ static struct flb_dns_lookup_context *flb_net_dns_lookup_context_create(
return NULL;
}

/* c-ares options: Set the transport layer to the desired protocol and
* the number of retries to 2
*/
/* c-ares options: Set the transport layer to the desired protocol */

optmask = ARES_OPT_FLAGS | ARES_OPT_TRIES;
opts.tries = 2;
optmask = ARES_OPT_FLAGS;

if (dns_mode == FLB_DNS_USE_TCP) {
opts.flags = ARES_FLAG_USEVC;
Expand Down

0 comments on commit a2fc10e

Please sign in to comment.