📄 tzfile.5
字号:
.TH tzfile 5.SH Nametzfile \- time zone information.SH Syntax.B #include <tzfile.h>.SH DescriptionThe time zone information files used by.PN tzsetbegin with bytes reserved for future use,followed by three 4-byte values of type``long'', written in a ``standard'' byte order(the high-order byte of the value is written first).These values are,in order:.IP tzh_timecnt 15The number of transition times for which data is storedin the file..IP tzh_typecntThe number of local time types for which data is storedin the file (must not be zero)..IP tzh_charcntThe number of characters of ``time zone abbreviation strings''stored in the file..IPThis header is followed by.PN tzh_timecnt4-byte values of type ``long'',sorted in ascending order.These values are written in ``standard'' byte order.Each is used as a transition time (as returned by.PN timeat which the rules for computing local time change).Next come.PN tzh_timecnt1-byte values of type ``unsigned char''.Each one tells which of the different types of local time typesdescribed in the file is associated with the same-indexed transition time.These values serve as indices into an array of.I ttinfostructures that appears next in the file; these structures are defined as follows:.EXstruct ttinfo { long tt_gmtoff; int tt_isdst; unsigned int tt_abbrind;};.EEEach structure is written as a 4-byte value for.PN tt_gmtoffof type ``long'',in a standard byte order, followed by a 1-byte value for.PN tt_isdstand a 1-byte value for.PN tt_abbrind .In each structure,.PN tt_gmtoffgives the number of seconds to be added to GMT,.PN tt_isdsttells whether.PN tm_isdstshould be set by.PN localtimeand.PN tt_abbrindserves as an index into the array of time zone abbreviation charactersthat follows the.PN ttinfostructure or structures in the file..PPThe.PN localtimecall uses the first standard-time.PN ttinfostructure in the file(or simply the first.PN ttinfostructure, in the absence of a standard-time structure)if either.PN tzh_timecntis zero or the time argument is less than the first transition time recordedin the file..SH See Alsoctime(3)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -