mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
ITS#8460 fix slap_op_time
broken in 2d5996ac60
Was allowing tv_usec to exceed 999999
This commit is contained in:
parent
5e6aadd779
commit
f6510ec83b
@ -173,11 +173,11 @@ slap_op_time(time_t *t, int *nop)
|
||||
tv.tv_usec <= last_time.tv_usec ) {
|
||||
tv.tv_sec = last_time.tv_sec;
|
||||
tv.tv_usec = last_time.tv_usec + 1;
|
||||
if (tv.tv_usec >= 1000000) {
|
||||
tv.tv_usec -= 1000000;
|
||||
tv.tv_sec++;
|
||||
last_time.tv_sec = tv.tv_sec;
|
||||
}
|
||||
}
|
||||
if (tv.tv_usec >= 1000000) {
|
||||
tv.tv_usec -= 1000000;
|
||||
tv.tv_sec++;
|
||||
last_time.tv_sec = tv.tv_sec;
|
||||
}
|
||||
last_time.tv_usec = tv.tv_usec;
|
||||
ldap_pvt_thread_mutex_unlock( &slap_op_mutex );
|
||||
|
Loading…
Reference in New Issue
Block a user