Index: runtime/vm/thread_pool.cc |
=================================================================== |
--- runtime/vm/thread_pool.cc (revision 45808) |
+++ runtime/vm/thread_pool.cc (working copy) |
@@ -274,11 +274,8 @@ |
// Release monitor while handling the task. |
monitor_.Exit(); |
- Thread::EnsureInit(); |
task->Run(); |
ASSERT(Isolate::Current() == NULL); |
- // Prevent unintended sharing of state between tasks. |
- Thread::CleanUp(); |
delete task; |
monitor_.Enter(); |
@@ -333,6 +330,9 @@ |
ml.Notify(); |
} |
delete worker; |
+#if defined(TARGET_OS_WINDOWS) |
+ Thread::CleanUp(); |
+#endif |
} |
} // namespace dart |