fix bug in task freeing
authorSimon Marlow <simonmar@microsoft.com>
Wed, 9 Aug 2006 14:12:25 +0000 (14:12 +0000)
committerSimon Marlow <simonmar@microsoft.com>
Wed, 9 Aug 2006 14:12:25 +0000 (14:12 +0000)
rts/Task.c

index 57497e4..dcfa5b5 100644 (file)
@@ -74,7 +74,7 @@ stopTaskManager (void)
               tasksRunning);
 
     ACQUIRE_LOCK(&sched_mutex);
-    for (task = task_free_list; task != NULL; next) {
+    for (task = task_free_list; task != NULL; task = next) {
         next = task->next;
         stgFree(task);
     }