(Cherry-pick commit
218bfbfa from 'master' branch.)
* misc.c [!GC_DISABLE_INCREMENTAL && !KEEP_BACK_PTRS]
(GC_enable_incremental): Wrap GC_gcollect_inner and GC_read_dirty calls
into DISABLE/RESTORE_CANCEL.
}
if (GC_incremental && !GC_dont_gc) {
/* Can't easily do it if GC_dont_gc. */
+ IF_CANCEL(int cancel_state;)
+
+ DISABLE_CANCEL(cancel_state);
if (GC_bytes_allocd > 0) {
/* There may be unmarked reachable objects. */
GC_gcollect_inner();
/* clean since nothing can point to an */
/* unmarked object. */
GC_read_dirty();
+ RESTORE_CANCEL(cancel_state);
}
}
UNLOCK();