--- libaitsched/src/tasks.c 2013/08/22 15:28:04 1.18 +++ libaitsched/src/tasks.c 2013/08/26 07:30:07 1.18.2.1 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: tasks.c,v 1.18 2013/08/22 15:28:04 misho Exp $ +* $Id: tasks.c,v 1.18.2.1 2013/08/26 07:30:07 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -149,6 +149,24 @@ _sched_threadWrapper(sched_task_t *t) pthread_cleanup_pop(42); TASK_ROOT(t)->root_ret = ret; pthread_exit(ret); +} +#endif + +#if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) +void * +_sched_rtcWrapper(sched_task_t *t) +{ + void *ret = NULL; + sched_task_func_t func; + + if (!t || !TASK_ROOT(t)) + return NULL; + else + func = TASK_FUNC(t); + + ret = func(t); + timer_delete((timer_t) TASK_DATLEN(t)); + return ret; } #endif