unregister_task(): Set error status to E_TASK_UNREGISTERED
[paraslash.git] / sched.c
diff --git a/sched.c b/sched.c
index 2500406..b9d6428 100644 (file)
--- a/sched.c
+++ b/sched.c
@@ -41,8 +41,7 @@ void unregister_task(struct task *t)
                list_del(&t->pre_select_node);
        if (t->post_select)
                list_del(&t->post_select_node);
-       if (t->error >= 0)
-               t->error = -E_TASK_KILLED;
+       t->error = -E_TASK_UNREGISTERED;
 };