In the message <
cf683a060809132003j724d7ef5m9cbae52f483e3043@...>
dated Sat, Sep 13, 2008 at 08:03:30PM -0700,
Matthew Dempsky <
matthew.dempsky@...> writes:
> > Should I rather do this using timegm(3) and throw away
> > the rather naive computation algorithm in univ_to_local()?
> > (Note that this is not necessarily portable either)
>
> mktime(3) is defined by POSIX.
mktime() certainly is, but timegm() isn't, AFAIK.
An example implementation in the following URL will not be thread-safe,
due to the usage of getenv() and setenv().
http://developer.apple.com/documentation/Darwin/Reference/ManPages/man3/timegm.3.htmlBTW local_to_univ() in erl_time_sup.c uses mktime(), and I see no
problem with it.
Kenji Rikitake
_______________________________________________
erlang-patches mailing list
erlang-patches@...
http://www.erlang.org/mailman/listinfo/erlang-patches