summaryrefslogtreecommitdiff
path: root/src/libstddjb/localtm_from_sysclock.c
blob: 02a9f67a85027115c360f865a38f03dac42fd2c9 (plain)
1
2
3
4
5
6
7
8
9
10
11
/* ISC license. */

#include <time.h>
#include <skalibs/uint64.h>
#include <skalibs/djbtime.h>

int localtm_from_sysclock (struct tm *l, uint64_t u, int tz)
{
  if (!ltm64_from_sysclock(&u)) return 0 ;
  return localtm_from_ltm64(l, u, !!tz) ;
}