X-Git-Url: https://pd.if.org/git/?p=pdclib;a=blobdiff_plain;f=opt%2Fnothread%2Fmtx_timedlock.c;h=c9d8f205a523c52fb0384baab1bb8f96aa06b252;hp=b8166b5b97cfee37b74271635a5114db62e19b11;hb=abc15df6b9fae3374d24c7cf5c3ab94c605b2a6d;hpb=b41576197133c1211d6ec353faf93f505f573b8a diff --git a/opt/nothread/mtx_timedlock.c b/opt/nothread/mtx_timedlock.c index b8166b5..c9d8f20 100644 --- a/opt/nothread/mtx_timedlock.c +++ b/opt/nothread/mtx_timedlock.c @@ -1,6 +1,18 @@ -#include - -int mtx_timedlock(mtx_t *restrict mtx, const struct timespec *restrict ts) -{ - return mtx_lock(mtx); -} \ No newline at end of file +#ifndef REGTEST +#include + +int mtx_timedlock(mtx_t *restrict mtx, const struct timespec *restrict ts) +{ + return mtx_lock(mtx); +} +#endif + +#ifdef TEST +#include "_PDCLIB_test.h" + +int main( void ) +{ + return TEST_RESULTS; +} + +#endif