[fpc-devel] Problem with Now() and time changed by ntpd
Michael Van Canneyt
michael at freepascal.org
Mon Oct 31 20:17:46 CET 2011
On Mon, 31 Oct 2011, zeljko wrote:
>
> Hi,
>
>
> I have daemon which uses Now() for getting current date/time, but something is wrong, time on server changed from 03:00
> to 02:00 this weekend, but daemon's Now() was on old time ... until now ... I've just restarted it and now it applied
> new time.
>
> fpc-2.4.5, centos 5.5 ....
>
> Also this confirms something what happens sometimes when ntpd changes time ...
>
> Any hints ? What to do ? Any workaround ?
It's probably the timezone information which is loaded only once at program startup.
This has been reported before, but no satisfying solution was found at the time.
re-reading this file at each now() would be extremely slowing.
Michael.
More information about the fpc-devel
mailing list