I am using RHEL 5.3 (linux 2.6.18)
I have a legacy code Which depends on ftime (3). Timezone and dstflag are not supported from me
now from the ftime (3) man page. gettimeofday (3) fields are not supported.
How can I get timezone and DST?
Thanks
You can tzset (3)
:
#define _XOPEN_SOURCE # & lt; Time.h> Include # include & lt; Stdio.h & gt; Int main (zero) {tzset (); Printf ("% ld,% d \ n", timezone, daylight); }
Which of the "-3600, 1" prints on my system?
tzset
also fills the array four * tzname [2]
with the names of the standard and daylight saving time timezones names.
Comments
Post a Comment