summaryrefslogtreecommitdiff
path: root/src/libstddjb/tai_from_sysclock.c
blob: 006c859bb7b5367b3b857e694d2b2866c8acad32 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/* ISC license. */

#include <skalibs/config.h>
#include <skalibs/uint64.h>
#include <skalibs/tai.h>

#ifdef SKALIBS_FLAG_CLOCKISTAI

int tai_from_sysclock (tai *t, uint64_t u)
{
  return tai_u64(t, u + 10U) ;
}

#else

#include <skalibs/djbtime.h>

int tai_from_sysclock (tai *t, uint64_t u)
{
  return tai_from_utc(t, u) ;
}

#endif