Christos Zoulas writes:
What I want to achieve is to be able to use the time functions in a multi-threaded program that can handle multiple timezones at the same time. Right now, this is impossible, because the notion of timezone is expressed through the environment. I was careful to re-use the existing code and not change existing functionality so the following routines are just an add-on.
I implemented something similar back in 2001, based on the then-current version of tzcode with some input from its FreeBSD variant. I've attached my original message describing my implementation. It's based on tzcode2001c. It might be a bit of work to update it to the current version of tzcode; I've not tried it. Licensed under the standard tzcode license, i.e. public domain. For discussion of it, check out the archives of the tz list from June 2001. -- Jonathan Lennox lennox@cs.columbia.edu