From: Jong Hyuk Choi Date: Tue, 20 May 2003 22:13:21 +0000 (+0000) Subject: runqueue update according to the idle timer change X-Git-Tag: OPENLDAP_REL_ENG_2_2_0ALPHA~96 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=2b62559aa582bd6af0178faa8f6fda605d23cf5e;p=openldap runqueue update according to the idle timer change --- diff --git a/servers/slapd/daemon.c b/servers/slapd/daemon.c index b6d1dc42aa..2afa9767ab 100644 --- a/servers/slapd/daemon.c +++ b/servers/slapd/daemon.c @@ -1356,11 +1356,10 @@ slapd_daemon_task( time_t diff = difftime( cat->tv_sec, now ); if ( diff == 0 ) diff = tdelta; - if ( tvp == NULL ) - tvp = &tv; - if ( diff < tv.tv_sec ) { + if ( tvp == NULL || diff < tv.tv_sec ) { tv.tv_sec = diff; tv.tv_usec = 0; + tvp = &tv; } } #endif