I think you may found a kernel bug:

> clock_gettime03    3  FAIL  :  clock_gettime(2) failed to produce expected
> error; 22 , errno : EINVAL and got 0


linux/kernel/posix-timers.c:
static inline int invalid_clockid(const clockid_t which_clock)
{
        if (which_clock < 0)    /* CPU clock, posix_cpu_* will check it */
                return 0;
        if ((unsigned) which_clock >= MAX_CLOCKS)
                return 1;
        if (posix_clocks[which_clock].clock_getres != NULL)
                return 0;
        if (posix_clocks[which_clock].res != 0)
                return 0;
        return 1;
}



I think following line:
        if ((unsigned) which_clock >= MAX_CLOCKS)
                return 1;

should be 
        if ((unsigned) which_clock >= MAX_CLOCKS)
                return 0;



Sorry, I don't have much time to dig more.

Masatake YAMATO

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Ltp-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ltp-list

Reply via email to