There's no need to mark the signal handler here, because it is stored
in a StablePtr and hence is a root anyway. Furthermore, the call to
evac() was passing the address of a local variable, which turned out
to be harmless for copying GC, but fatal for compacting GC: compacting
GC assumes that the addresses of the roots are the same each time.
Fixes: possibly #783, possibly #776, definitely #787
*/
void markSignalHandlers (evac_fn evac)
{
- if (console_handler >= 0) {
- StgPtr p = deRefStablePtr((StgStablePtr)console_handler);
- evac((StgClosure**)(void *)&p);
- }
+ // nothing to mark; the console handler is a StablePtr which is
+ // already treated as a root by the GC.
}