From: Martin Burnicki Date: Tue, 8 Apr 2008 10:20:22 +0000 (+0200) Subject: Always sleep a little before calling doconfigure() to make sure the network is comple... X-Git-Tag: NTP_4_2_5P116~3^2~1^2~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=62b537c073742bb66dd27f10e29089da47175598;p=thirdparty%2Fntp.git Always sleep a little before calling doconfigure() to make sure the network is completely up. bk: 47fb46e6ThlpuUlCRxt58434Qvj6zQ --- diff --git a/ntpd/ntp_intres.c b/ntpd/ntp_intres.c index 345e42577..18920285e 100644 --- a/ntpd/ntp_intres.c +++ b/ntpd/ntp_intres.c @@ -258,12 +258,7 @@ ntp_intres(void) (void) unlink(req_file); /* - * Sleep a little to make sure the server is completely up - */ - sleep(SLEEPTIME); - - /* - * Set up the timers to do first try immediately. + * Set up the timers to do first shot immediately. */ resolve_timer = 0; resolve_value = MINRESOLVE; @@ -273,6 +268,10 @@ ntp_intres(void) checkparent(); if (resolve_timer == 0) { + /* + * Sleep a little to make sure the network is completely up + */ + sleep(SLEEPTIME); doconfigure(1); /* prepare retry, in case there's more work to do */