The following is a confirmation from Kevin Kenny (author of the latest clock code) about the state of 8.5 clock:

Jeff Hobbs wrote:
I haven't looked at Tcl 8.5 source, but has "clock ... -gmt" been fixed so that it doesn't diddle with env(TZ) any more, which isn't thread-safe. I remember that there's Tcl mutexes around the env(TZ) diddling, but that isn't safe when an application embeds Tcl and modifies env(TZ) as well but doesn't have access to the mutex that Tcl's "clock" is using.

As of 8.5:

[clock] reads $env(TZ) but no longer needs to modify it. The
'-gmt' and '-timezone' flags are handled within the Tcl library.
We don't use the system 'strftime' either. We use 'localtime'
only as a last resort when we can't determine time zone any
other way. And that includes using 'localtime_r' where
appropriate. (Some systems have a thread-safe 'localtime' that
returns its structure in thread-local storage.)

So you should be safe.

--
73 de ke9tv/2, Kevin


--
AOLserver - http://www.aolserver.com/

To Remove yourself from this list, simply send an email to 
<lists...@listserv.aol.com> with the
body of "SIGNOFF AOLSERVER" in the email message. You can leave the Subject: 
field of your email blank.

Reply via email to