Merge branch 'refs/heads/t/portable_io'
[paraslash.git] / sched.c
diff --git a/sched.c b/sched.c
index 3ba7a5e83d65aac415e8820dfc6e7c43398f8419..297348a16e0c3e85ea683dccf681c2ecbf278a4b 100644 (file)
--- a/sched.c
+++ b/sched.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (C) 2006-2014 Andre Noll <maan@tuebingen.mpg.de>
+ * Copyright (C) 2006 Andre Noll <maan@tuebingen.mpg.de>
  *
  * Licensed under the GPL v2. For licencing details see COPYING.
  */
@@ -66,7 +66,10 @@ static void sched_preselect(struct sched *s)
 
 static void unlink_and_free_task(struct task *t)
 {
-       PARA_INFO_LOG("freeing task %s\n", t->name);
+       PARA_INFO_LOG("freeing task %s (%s)\n", t->name, t->status < 0?
+               para_strerror(-t->status) :
+               (t->status == TS_DEAD? "[dead]" : "[running]"));
+
        list_del(&t->node);
        free(t->name);
        free(t);
@@ -384,7 +387,7 @@ void sched_min_delay(struct sched *s)
  * function does nothing. Otherwise the timeout for the next select() call is
  * set to the given value.
  *
- * \sa sched_request_timeout_ms().
+ * \sa \ref sched_request_timeout_ms().
  */
 void sched_request_timeout(struct timeval *to, struct sched *s)
 {
@@ -417,7 +420,7 @@ void sched_request_timeout_ms(long unsigned ms, struct sched *s)
  * \return If \a barrier is in the past, this function does nothing and returns
  * zero. Otherwise it returns one.
  *
- * \sa sched_request_barrier_or_min_delay().
+ * \sa \ref sched_request_barrier_or_min_delay().
  */
 int sched_request_barrier(struct timeval *barrier, struct sched *s)
 {
@@ -438,7 +441,7 @@ int sched_request_barrier(struct timeval *barrier, struct sched *s)
  * \return If \a barrier is in the past, this function requests a minimal
  * timeout and returns zero. Otherwise it returns one.
  *
- * \sa sched_min_delay(), sched_request_barrier().
+ * \sa \ref sched_min_delay(), \ref sched_request_barrier().
  */
 int sched_request_barrier_or_min_delay(struct timeval *barrier, struct sched *s)
 {