[BUG] GTimeZone broken on Windows
Lutz Vieweg
lvml at 5t9.de
Wed Feb 27 09:53:27 PST 2013
On 02/27/2013 06:47 PM, Lubomir I. Ivanov wrote:
> static timestamp_t current_time_notz(void)
> {
> time_t now = time(NULL);
> struct tm *local = localtime(&now);
> return utc_mktime(local);
> }
The man page of time() states:
> time() returns the time since the Epoch (00:00:00 UTC, January 1, 1970), measured in seconds.
So... why is
> time_t now = time(NULL);
> struct tm *local = localtime(&now);
> return utc_mktime(local);
better than
return (timestamp_t)time(NULL);
?
Regards,
Lutz Vieweg
More information about the subsurface
mailing list