summaryrefslogtreecommitdiff
path: root/rts/Schedule.c
diff options
context:
space:
mode:
authorSimon Marlow <marlowsd@gmail.com>2009-08-19 12:32:08 +0000
committerSimon Marlow <marlowsd@gmail.com>2009-08-19 12:32:08 +0000
commit3a886477def20cfaaacb87a784917b5c6a3238b0 (patch)
treeb9ca7a107159719a5b4fd5ec20486798d934a26f /rts/Schedule.c
parent2aea029422dc06f50aab82b35e5b3b0a42641ded (diff)
downloadhaskell-3a886477def20cfaaacb87a784917b5c6a3238b0.tar.gz
Detect C finalizer callbacks in rts_lock() instead of schedule()
Otherwise, finalizer callbacks cause a deadlock in the threaded RTS (including GHCi)
Diffstat (limited to 'rts/Schedule.c')
-rw-r--r--rts/Schedule.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/rts/Schedule.c b/rts/Schedule.c
index dd33f6f2d2..70601c3f56 100644
--- a/rts/Schedule.c
+++ b/rts/Schedule.c
@@ -252,14 +252,6 @@ schedule (Capability *initialCapability, Task *task)
"### NEW SCHEDULER LOOP (task: %p, cap: %p)",
task, initialCapability);
- if (running_finalizers) {
- errorBelch("error: a C finalizer called back into Haskell.\n"
- " This was previously allowed, but is disallowed in GHC 6.10.2 and later.\n"
- " To create finalizers that may call back into Haskll, use\n"
- " Foreign.Concurrent.newForeignPtr instead of Foreign.newForeignPtr.");
- stg_exit(EXIT_FAILURE);
- }
-
schedulePreLoop();
// -----------------------------------------------------------