mirror of git://sourceware.org/git/glibc.git
Remember we switched to single-request mode.
This change prevents repetition in most later calls of the resolver in case the DNS server or the network connection is broken.
This commit is contained in:
parent
88ea382fda
commit
310647e980
|
|
@ -1,3 +1,8 @@
|
||||||
|
2009-06-11 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
|
* resolv/res_send.c (send_dg): Remember we switched to
|
||||||
|
single-request mode.
|
||||||
|
|
||||||
2009-06-09 Ulrich Drepper <drepper@redhat.com>
|
2009-06-09 Ulrich Drepper <drepper@redhat.com>
|
||||||
|
|
||||||
* dlfcn/dlfcn.h: Remove comma at end of enum.
|
* dlfcn/dlfcn.h: Remove comma at end of enum.
|
||||||
|
|
|
||||||
|
|
@ -1008,7 +1008,7 @@ send_dg(res_state statp,
|
||||||
seconds /= statp->nscount;
|
seconds /= statp->nscount;
|
||||||
if (seconds <= 0)
|
if (seconds <= 0)
|
||||||
seconds = 1;
|
seconds = 1;
|
||||||
bool single_request = ((statp->options) & RES_SNGLKUP) != 0;// XXX
|
bool single_request = (statp->options & RES_SNGLKUP) != 0;// XXX
|
||||||
int save_gotsomewhere = *gotsomewhere;
|
int save_gotsomewhere = *gotsomewhere;
|
||||||
retry:
|
retry:
|
||||||
evNowTime(&now);
|
evNowTime(&now);
|
||||||
|
|
@ -1059,6 +1059,7 @@ send_dg(res_state statp,
|
||||||
have received the first answer. */
|
have received the first answer. */
|
||||||
if (!single_request)
|
if (!single_request)
|
||||||
{
|
{
|
||||||
|
statp->options |= RES_SNGLKUP;
|
||||||
single_request = true;
|
single_request = true;
|
||||||
*gotsomewhere = save_gotsomewhere;
|
*gotsomewhere = save_gotsomewhere;
|
||||||
goto retry;
|
goto retry;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue