Project

General

Profile

Bug #14807 ยป 0001-Initialize-condattr_monotonic-via-pthread_condattr_i.patch

jeremyevans0 (Jeremy Evans), 06/01/2018 08:48 PM

View differences:

thread_pthread.c
399 399
{
400 400
#if defined(HAVE_PTHREAD_CONDATTR_SETCLOCK)
401 401
    if (condattr_monotonic) {
402
        int r = pthread_condattr_setclock(condattr_monotonic, CLOCK_MONOTONIC);
402
        int r = pthread_condattr_init(condattr_monotonic);
403
        if (r == 0) {
404
            r = pthread_condattr_setclock(condattr_monotonic, CLOCK_MONOTONIC);
405
        }
403 406
        if (r) condattr_monotonic = NULL;
404 407
    }
405 408
#endif
406
-