In my app compiled on another linux I am getting Assertion 'clock_gettime(clock_id, &ts) == 0' failed at src/shared/time-util.c:34, function now(). Aborting. when calling gettimeofday() on an update CentOS (did not fail in 7.5). Is it possible that the update has changed the size of the types in the timeval struct and causing the crash? Or has there be some for of bug fix etc?
Regards
On 2/6/19 4:04 AM, david allan finch wrote:
In my app compiled on another linux I am getting Assertion 'clock_gettime(clock_id, &ts) == 0' failed at src/shared/time-util.c:34, function now(). Aborting. when calling gettimeofday() on an update CentOS (did not fail in 7.5). Is it possible that the update has changed the size of the types in the timeval struct and causing the crash? Or has there be some for of bug fix etc?
The documentation for clock_gettime doesn't indicate that it would fail on a struct size change (which is typically not something that can be detected in C to begin with), so that's unlikely.
Documented failure conditions for clock_gettime are an invalid "ts" pointer, or an unsupported clock type in clock_id.
If you're confident that this is failing in a call to libc's gettimeofday(), then try rolling back glibc to an earlier release. If that resolves the problem, you might have found a bug in glibc.