1
0
mirror of https://github.com/samba-team/samba.git synced 2025-06-22 07:17:05 +03:00

s4/ldb: fix standalone build

This commit is contained in:
Björn Jacke 2010-09-01 11:22:09 +02:00
parent 5568ceda47
commit d45f901b93

View File

@ -45,12 +45,16 @@ static struct ldb_cmdline *options;
static void _start_timer(void)
{
clock_gettime_mono(&tp1);
if (clock_gettime(CUSTOM_CLOCK_MONOTONIC, &tp1) != 0) {
clock_gettime(CLOCK_REALTIME, &tp1);
}
}
static double _end_timer(void)
{
clock_gettime_mono(&tp2);
if (clock_gettime(CUSTOM_CLOCK_MONOTONIC, &tp2) != 0) {
clock_gettime(CLOCK_REALTIME, &tp2);
}
return((tp2.tv_sec - tp1.tv_sec) +
(tp2.tv_nsec - tp1.tv_nsec)*1.0e-9);
}