From: simonmar Date: Fri, 11 Feb 2005 12:20:12 +0000 (+0000) Subject: [project @ 2005-02-11 12:20:12 by simonmar] X-Git-Tag: Initial_conversion_from_CVS_complete~1081 X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=commitdiff_plain;h=a186d6f72aa221772ffeccb99c6c538c4505b0d7 [project @ 2005-02-11 12:20:12 by simonmar] Fix a bug: thunk_selector_depth was being incremented before checking that we had reached the depth limit, and not decremented if we had reached the limit. --- diff --git a/ghc/rts/GC.c b/ghc/rts/GC.c index a57fa2c..8830582 100644 --- a/ghc/rts/GC.c +++ b/ghc/rts/GC.c @@ -2117,10 +2117,10 @@ selector_loop: // check that we don't recurse too much, re-using the // depth bound also used in evacuate(). - thunk_selector_depth++; - if (thunk_selector_depth > MAX_THUNK_SELECTOR_DEPTH) { + if (thunk_selector_depth >= MAX_THUNK_SELECTOR_DEPTH) { break; } + thunk_selector_depth++; val = eval_thunk_selector(info->layout.selector_offset, (StgSelector *)selectee);