From: sewardj Date: Fri, 12 Nov 1999 14:32:44 +0000 (+0000) Subject: [project @ 1999-11-12 14:32:44 by sewardj] X-Git-Tag: Approximately_9120_patches~5562 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=baa5bc8bbb50341f337d02d420e2caf49e2f7322;p=ghc-hetmet.git [project @ 1999-11-12 14:32:44 by sewardj] Install control-c signal handler in interpreter() after call to initialize, since that calls startupHaskell, which trashes previous signal settings. --- diff --git a/ghc/interpreter/hugs.c b/ghc/interpreter/hugs.c index c8d2132..07a5316 100644 --- a/ghc/interpreter/hugs.c +++ b/ghc/interpreter/hugs.c @@ -9,8 +9,8 @@ * included in the distribution. * * $RCSfile: hugs.c,v $ - * $Revision: 1.17 $ - * $Date: 1999/11/09 00:40:11 $ + * $Revision: 1.18 $ + * $Date: 1999/11/12 14:32:44 $ * ------------------------------------------------------------------------*/ #include @@ -576,7 +576,9 @@ String s; { /* return FALSE if none found. */ default : if (strcmp("98",s)==0) { if (heapBuilt() && ((state && !haskell98) || (!state && haskell98))) { - FPrintf(stderr,"Haskell 98 compatibility cannot be changed while the interpreter is running\n"); + FPrintf(stderr, + "Haskell 98 compatibility cannot be changed" + " while the interpreter is running\n"); } else { haskell98 = state; } @@ -1900,6 +1902,9 @@ String argv[]; { forHelp(); } + /* initialize calls startupHaskell, which trashes our signal handlers */ + breakOn(TRUE); + for (;;) { Command cmd; everybody(RESET); /* reset to sensible initial state */