On 1/24/22 21:21, Adriano dos Santos Fernandes wrote:
As I talked earlier, FB 3 apparently was not affected. Now looking for details I see that configure.ac has: case $host in *-darwin*) ac_cv_func_clock_gettime=no ;; *) AC_SEARCH_LIBS(clock_gettime, rt) AC_CHECK_FUNCS(clock_gettime) ;; esac Leading to imprecise curTime() (MasterImplementation), not firing timers in correct moment.
Or not firing at all: "If the processor time used is not available or its value cannot be represented, the function returns the value (clock_t) -1." That's enough for plugins to be not unloaded.
Can you check code based on this method? ( I do not provide URL cause it's russian page)
#if defined(__MACH__) && !defined(CLOCK_REALTIME) #include <sys/time.h> #define CLOCK_REALTIME 0 // clock_gettime is not implemented on older versions of OS X (< 10.12). // If implemented, CLOCK_REALTIME will have already been defined. int clock_gettime(int /*clk_id*/, struct timespec* t) { struct timeval now; int rv = gettimeofday(&now, NULL); if (rv) return rv; t->tv_sec = now.tv_sec; t->tv_nsec = now.tv_usec * 1000; return 0; } #endif
This is introduced in this commit: commit 20542beae18d13c3d2453a9ac2af51b095136c16 Author: paulbeach <pbe...@ibphoenix.com> Date: Mon Jul 17 14:13:23 2017 +0200 clock_gettime is only supported on 10.12, but lazy binding means that the code will compile even though version-min is set to 10.7 and Firebird will then throw a run time error on any versions of OSX post 10.7 and pre 10.12 - disable the function Should this be maintained in FB 3?
Breaking support of old OS versions in dot release is bad idea on my mind. Firebird-Devel mailing list, web interface at https://lists.sourceforge.net/lists/listinfo/firebird-devel