INtime SDK Help
time macros, _tzset_ptr

Accesses daylight, timezone, and tzname environment variables.

#include <time.h>
#include <reent.h>

struct _tzset {
        char *_tzname[2];
        long _timezone;
        int _daylight;
struct _tzset  *_tzset_ptr (void);
#define daylight (_tzset_ptr->_daylight)
#define timezone (_tzset_ptr->_timezone)
#define tzname (_tzset_ptr->_tzname);


The daylight macro accesses the _daylight flag.

Value Description
1 Daylight-savings-time is in effect (default).
0 Daylight-savings-time is not in effect.

The timezone macro accesses the value that represents the difference in seconds between GMT and local time.

The tzname macro accesses a pair of pointers to the timezone name and daylight-savings-time name. For example, tzname[0] could point to EST and tzname[1] could point to EDT. The default strings are PST and PDT.

tzset_ptr uses the _tzset structure that contains members corresponding to tzname, timezone, and daylight. Each of these macros calls _tzset_ptr.

Return Values

Pointer to _tzset.
Null pointer.


Versions Defined in Include Link to
INtime 3.0 intime/rt/include/reent.h time.h

See Also

tzset, TIME.H