unregister_task(): Print what caused the task to shutdown.
authorAndre Noll <maan@systemlinux.org>
Tue, 1 Apr 2008 19:59:24 +0000 (21:59 +0200)
committerAndre Noll <maan@systemlinux.org>
Tue, 1 Apr 2008 19:59:24 +0000 (21:59 +0200)
sched.c

diff --git a/sched.c b/sched.c
index b9d642864624cd796e3853331cc9a652378c41c5..9b0bddc13e36d8fa9636c292b4c243e2e0416f86 100644 (file)
--- a/sched.c
+++ b/sched.c
@@ -36,7 +36,8 @@ void unregister_task(struct task *t)
 {
        if (!initialized)
                return;
-       PARA_INFO_LOG("unregistering %s (%p)\n", t->status, t);
+       PARA_INFO_LOG("unregistering %s (%s)\n", t->status,
+               t->error <0? para_strerror(-t->error) : "shutdown");
        if (t->pre_select)
                list_del(&t->pre_select_node);
        if (t->post_select)