time and time zones

I am setting the time zone by changing the sysinit line:

export TZ=est05edt04,M4.1.0/2,M10.5.0/2

with

export TZ=cst6cdt5,M4.1.0/2,M10.5.0/2

the date command returns what I would believe to be correct however, any
localtime() call returns Eastern time.

Is there a set of est, cst, pst time descriptors that have to be used? From
my reading, these are just descriptors.

Doug

I believe that the issue is that I’m setting the TZ env variable but it is
not getting loaded. But that does not explain the scenario of when I call
date it returns the proper time but localtime() (which is supposed to call
tzset) it returns the default of EST.

How do you force the env variables to be set and loaded?

Doug

In the sysinit, I have the line as shown below.
“Doug Rixmann” <rixmannd@rdsdata.com> wrote in message
news:afseo5$rhf$1@inn.qnx.com

I am setting the time zone by changing the sysinit line:

export TZ=est05edt04,M4.1.0/2,M10.5.0/2

with

export TZ=cst6cdt5,M4.1.0/2,M10.5.0/2

the date command returns what I would believe to be correct however, any
localtime() call returns Eastern time.

Is there a set of est, cst, pst time descriptors that have to be used?
From
my reading, these are just descriptors.

Doug

Doug Rixmann wrote:

I believe that the issue is that I’m setting the TZ env variable but it is
not getting loaded. But that does not explain the scenario of when I call
date it returns the proper time but localtime() (which is supposed to call
tzset) it returns the default of EST.

How do you force the env variables to be set and loaded?
According to the book, tzset() looks at the env variable. What is it?

(sin -P<exec_name> env, or look at the env of whatever starts the
process.) You need to be root or the same uid as the process to see
the environment variables.

Richard

Doug

In the sysinit, I have the line as shown below.
“Doug Rixmann” <> rixmannd@rdsdata.com> > wrote in message
news:afseo5$rhf$> 1@inn.qnx.com> …
I am setting the time zone by changing the sysinit line:

export TZ=est05edt04,M4.1.0/2,M10.5.0/2

with

export TZ=cst6cdt5,M4.1.0/2,M10.5.0/2

the date command returns what I would believe to be correct however, any
localtime() call returns Eastern time.

Is there a set of est, cst, pst time descriptors that have to be used?
From
my reading, these are just descriptors.

Doug