GC_gcollect();
}
-#ifdef UNIX_LIKE
+#if defined(UNIX_LIKE) && !defined(NO_DEBUGGING)
static void looping_handler(int sig)
{
GC_err_printf("Caught signal %d: looping in handler\n", sig);
- for (;;) {}
+ for (;;) {
+ /* empty */
+ }
}
static GC_bool installed_looping_handler = FALSE;
(void)WRITE(GC_stderr, (void *)("\n"), 1);
}
- if (GETENV("GC_LOOP_ON_ABORT") != NULL) {
+# ifndef NO_DEBUGGING
+ if (GETENV("GC_LOOP_ON_ABORT") != NULL) {
/* In many cases it's easier to debug a running process. */
/* It's arguably nicer to sleep, but that makes it harder */
/* to look at the thread if the debugger doesn't know much */
for(;;) {
/* Empty */
}
- }
+ }
+# endif
}
#endif /* !SMALL_CONFIG */