From 424e0afadc8ed00f96330d869b774acde2865c37 Mon Sep 17 00:00:00 2001 From: Simon Marlow Date: Thu, 13 Nov 2008 15:45:42 +0000 Subject: [PATCH] move an assertion --- rts/Capability.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rts/Capability.c b/rts/Capability.c index 9b5d81d..0b3c844 100644 --- a/rts/Capability.c +++ b/rts/Capability.c @@ -725,8 +725,6 @@ shutdownCapability (Capability *cap, Task *task, rtsBool safe) { nat i; - ASSERT(sched_state == SCHED_SHUTTING_DOWN); - task->cap = cap; // Loop indefinitely until all the workers have exited and there @@ -736,6 +734,8 @@ shutdownCapability (Capability *cap, Task *task, rtsBool safe) // isn't safe, for one thing). for (i = 0; /* i < 50 */; i++) { + ASSERT(sched_state == SCHED_SHUTTING_DOWN); + debugTrace(DEBUG_sched, "shutting down capability %d, attempt %d", cap->no, i); ACQUIRE_LOCK(&cap->lock); -- 1.7.10.4