mirror of
https://github.com/samba-team/samba.git
synced 2025-08-02 00:22:11 +03:00
s3: use clock_gettime() in timespec_current()
This commit is contained in:
@ -356,11 +356,8 @@ struct timeval convert_timespec_to_timeval(const struct timespec ts)
|
|||||||
|
|
||||||
struct timespec timespec_current(void)
|
struct timespec timespec_current(void)
|
||||||
{
|
{
|
||||||
struct timeval tv;
|
|
||||||
struct timespec ts;
|
struct timespec ts;
|
||||||
GetTimeOfDay(&tv);
|
clock_gettime(CLOCK_REALTIME, &ts);
|
||||||
ts.tv_sec = tv.tv_sec;
|
|
||||||
ts.tv_nsec = tv.tv_usec * 1000;
|
|
||||||
return ts;
|
return ts;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user