benilla-re systems structs docs

tzinfo

global · crt

Address
0x883bb0 · 172 bytes, up to 0x883c5b
Type
uint8_t[172]
Meaning
Holds the TIME_ZONE_INFORMATION record __tzset_lk reads the zone into
Confidence
verified, proof one
Finding
crt/time#the-systems-zone

Finding: The system's zone in crt: calendar time

Without TZ, __tzset_lk asks GetTimeZoneInformation. _timezone is Bias in seconds, plus StandardBias when the standard date's month is set. With the daylight date's month and DaylightBias both set, _daylight is 1 and _dstbias (DaylightBias − StandardBias) · 60; otherwise both are 0. The two names go through WideCharToMultiByte into 63 bytes of _tzname's buffers, each emptied when the conversion fails or needs a default character. A failed call keeps the file's zone: 28800 seconds west, daylight time with _dstbias -3600, PST and PDT.

The derivation is in the doc.