BarryServer : Git

All the code for all my projects
// BarryServer : Git / Nucleus / commit / a1eaf264431107a223a69ca35d3b916243d7b90e / task / task.c

// Related

Nucleus

Barry Preemptive and lockless scheduler a1eaf26 (3 years, 2 months ago)
diff --git a/task/task.c b/task/task.c
index 3d84436..539026a 100644
--- a/task/task.c
+++ b/task/task.c
@@ -142,8 +142,8 @@ unblock_task(Task *task)
 {
 	lock(task);
 	task->state = READY;
-	enqueue_task(task);
 	unlock(task);
+	enqueue_task(task);
 }
 
 /* Find a task by ID */