MCPcopy Create free account
hub / github.com/eggert/tz / time2posix

Function time2posix

localtime.c:3069–3084  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3067}
3068
3069time_t
3070time2posix(time_t t)
3071{
3072 monotime_t now = get_monotonic_time();
3073 int err = lock();
3074 if (0 < err) {
3075 errno = err;
3076 return -1;
3077 }
3078 if (0 <= tz_change_interval || !lcl_is_set)
3079 tzset_unlocked(!err, false, now);
3080 if (lclptr)
3081 t = time2posix_z(lclptr, t);
3082 unlock(!err);
3083 return t;
3084}
3085
3086NETBSD_INSPIRED_EXTERN time_t
3087posix2time_z(struct state *sp, time_t t)

Callers

nothing calls this directly

Calls 5

get_monotonic_timeFunction · 0.85
lockFunction · 0.85
tzset_unlockedFunction · 0.85
time2posix_zFunction · 0.85
unlockFunction · 0.85

Tested by

no test coverage detected