FW: Question of time :-)

Olson, Arthur David OLSONA at dc37a.nci.nih.gov
Tue Apr 7 17:47:57 UTC 1998

Note that Guenther is not on the time zone mailing list.


From: 	Guenther Grau[SMTP:Guenther.Grau at bk.bosch.de]
Sent: 	Tuesday, April 07, 1998 12:36 PM
To: 	tz at elsie.nci.nih.gov
Subject: 	Question of time :-)


I don't know if this is correct address to send this to, but
I hope you'll be able to redirect me in case it's not :-)

In my application I need to know, the time difference
between any given time in any given timezone, and UTC. Is
this possible to do WITHOUT changing the TZ environment
variable? I cannot do this, because this is in a multithreaded
program, and changing TZ would affect other threads.
I cannot fork another process, as this takes too much time
and resources.

I need a program, that does sth. like this:
> echo $TZ
> date
Tue Apr  7 18:31:42 MET DST 1998
> calculateUtcDifference "1.2.1998 12:13 EST"
5 hours

I would be great if you knew a portable solution

Thanx in advance


More information about the tz mailing list