Skip to content

Commit

Permalink
Fix segfault with STM; fixes #8035. Patch from errge.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ian Lynagh committed Jul 7, 2013
1 parent a5913a2 commit 60cb478
Showing 1 changed file with 13 additions and 1 deletion.
14 changes: 13 additions & 1 deletion rts/Schedule.c
Expand Up @@ -2722,7 +2722,19 @@ raiseExceptionHelper (StgRegTable *reg, StgTSO *tso, StgClosure *exception)
tso->stackobj->sp = p;
return STOP_FRAME;

case CATCH_RETRY_FRAME:
case CATCH_RETRY_FRAME: {
StgTRecHeader *trec = tso -> trec;
StgTRecHeader *outer = trec -> enclosing_trec;
debugTrace(DEBUG_stm,
"found CATCH_RETRY_FRAME at %p during raise", p);
debugTrace(DEBUG_stm, "trec=%p outer=%p", trec, outer);
stmAbortTransaction(cap, trec);
stmFreeAbortedTRec(cap, trec);
tso -> trec = outer;
p = next;
continue;
}

default:
p = next;
continue;
Expand Down

0 comments on commit 60cb478

Please sign in to comment.