Diff for /libaitsched/src/hooks.c between versions 1.27.2.1 and 1.27.2.3

version 1.27.2.1, 2014/05/21 20:48:34 version 1.27.2.3, 2014/05/21 22:09:01
Line 267  sched_hook_cancel(void *task, void *arg __unused) Line 267  sched_hook_cancel(void *task, void *arg __unused)
 #endif  /* EVFILT_USER */  #endif  /* EVFILT_USER */
                 case taskTHREAD:                  case taskTHREAD:
 #ifdef HAVE_LIBPTHREAD  #ifdef HAVE_LIBPTHREAD
                        pthread_cancel((pthread_t) TASK_VAL(t));                        if (TASK_VAL(t))
                                 pthread_cancel((pthread_t) TASK_VAL(t));
 #endif  #endif
                         return NULL;                          return NULL;
 #if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) && defined(HAVE_TIMER_DELETE)  #if defined(HAVE_TIMER_CREATE) && defined(HAVE_TIMER_SETTIME) && defined(HAVE_TIMER_DELETE)
Line 739  sched_hook_fetch(void *root, void *arg __unused) Line 740  sched_hook_fetch(void *root, void *arg __unused)
 #else  #else
                 sched_timespec2val(&r->root_wait, &tv);                  sched_timespec2val(&r->root_wait, &tv);
                 timeout = &tv;                  timeout = &tv;
#endif  /* KQ_DISABLE */#endif  /* KQ_SUPPORT */
         } else if (sched_timespecisinf(&r->root_poll))          } else if (sched_timespecisinf(&r->root_poll))
                 timeout = NULL;                  timeout = NULL;
         else {          else {
Line 748  sched_hook_fetch(void *root, void *arg __unused) Line 749  sched_hook_fetch(void *root, void *arg __unused)
 #else  #else
                 sched_timespec2val(&r->root_poll, &tv);                  sched_timespec2val(&r->root_poll, &tv);
                 timeout = &tv;                  timeout = &tv;
#endif  /* KQ_DISABLE */#endif  /* KQ_SUPPORT */
         }          }
   
 #if SUP_ENABLE == KQ_ENABLE  #if SUP_ENABLE == KQ_ENABLE
Line 757  sched_hook_fetch(void *root, void *arg __unused) Line 758  sched_hook_fetch(void *root, void *arg __unused)
         rfd = xfd = r->root_fds[0];          rfd = xfd = r->root_fds[0];
         wfd = r->root_fds[1];          wfd = r->root_fds[1];
         if ((en = select(r->root_kq, &rfd, &wfd, &xfd, timeout)) == -1) {          if ((en = select(r->root_kq, &rfd, &wfd, &xfd, timeout)) == -1) {
#endif  /* KQ_DISABLE */#endif  /* KQ_SUPPORT */
                 if (r->root_hooks.hook_exec.exception) {                  if (r->root_hooks.hook_exec.exception) {
                         if (r->root_hooks.hook_exec.exception(r, NULL))                          if (r->root_hooks.hook_exec.exception(r, NULL))
                                 return NULL;                                  return NULL;
Line 1257  sched_hook_fetch(void *root, void *arg __unused) Line 1258  sched_hook_fetch(void *root, void *arg __unused)
                         break;                          break;
         if (i > 2)          if (i > 2)
                 r->root_kq = i + 1;                  r->root_kq = i + 1;
#endif  /* KQ_DISABLE */#endif  /* KQ_SUPPORT */
   
 skip_event:  skip_event:
         /* timer update & put in ready queue */          /* timer update & put in ready queue */

Removed from v.1.27.2.1  
changed lines
  Added in v.1.27.2.3


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>