> fpgettimeofday uses exactly what it says on the tin: gettimeofday. See > here: http://linux.die.net/man/2/gettimeofday > > The fp* functions in Linux by default call directly the kernel instead > of going through libc, thus avoiding the dependency on that library. > > Maybe a possibilty should be implemented in unit Unix to reread the > timezone file. This wouldn't solve your problem directly, but it would > at least provide the ability to update the time zone information without > restarting the application/service. The trigger would need to come from > an external source though (maybe by checking that timezone database that > was in the media some weeks ago).
There is possibility: gettimeofday() can result in incorrect timings if there are processes on your system that change the timer (ie, ntpd). On a "normal" linux, though, I believe the resolution of gettimeofday() is 10us. It can jump forward and backward and time, consequently, based on the processes running on your system. Look into clock_gettime(CLOCK_MONOTONIC) for timing intervals. It suffers from several less issues due to things like multi-core systems and external clock settings. Also, look into the clock_getres() function. So should I open an issue about this ? zeljko
_______________________________________________ fpc-devel maillist - fpc-devel@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-devel