summaryrefslogtreecommitdiff
path: root/rts/win32
diff options
context:
space:
mode:
authorIan Lynagh <igloo@earth.li>2010-10-28 13:48:54 +0000
committerIan Lynagh <igloo@earth.li>2010-10-28 13:48:54 +0000
commit723da2ed96068632ede8d1e8514dd02bbe1336ea (patch)
tree834f53b5f30de23b414970a9a3c4e0eef7801e2a /rts/win32
parentfb9d21af24d076b12abb9e22251aa327f82e8ea8 (diff)
downloadhaskell-723da2ed96068632ede8d1e8514dd02bbe1336ea.tar.gz
Replace some exit(n) calls with stg_exit(n); fixes trac #4445
Also changed exitcode of -1 to 1 in hpc.
Diffstat (limited to 'rts/win32')
-rw-r--r--rts/win32/seh_excn.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/rts/win32/seh_excn.h b/rts/win32/seh_excn.h
index 7d17465cd1..8829e840b7 100644
--- a/rts/win32/seh_excn.h
+++ b/rts/win32/seh_excn.h
@@ -25,11 +25,11 @@
*
* seh_excn provides two macros, BEGIN_CATCH and END_CATCH, which
* will catch such exceptions in the code they bracket and die by
- * printing a message and calling exit(1).
+ * printing a message and calling stg_exit(1).
*/
-#define ON_DIV_ZERO fprintf(stdout,"divide by zero\n"); fflush(stdout);exit(1)
-#define ON_STACK_OVERFLOW fprintf(stdout,"C stack overflow in generated code\n"); fflush(stdout); exit(1)
-#define ON_SIGSEGV fprintf(stdout,"Segmentation fault/access violation in generated code\n"); fflush(stdout); exit(1)
+#define ON_DIV_ZERO fprintf(stdout,"divide by zero\n"); fflush(stdout);stg_exit(1)
+#define ON_STACK_OVERFLOW fprintf(stdout,"C stack overflow in generated code\n"); fflush(stdout); stg_exit(1)
+#define ON_SIGSEGV fprintf(stdout,"Segmentation fault/access violation in generated code\n"); fflush(stdout); stg_exit(1)
#if defined(__MINGW32__)
extern jmp_buf seh_unwind_to;