From 2de3fd9474961c8afde2cd0893b825ffa15baaa0 Mon Sep 17 00:00:00 2001 From: vsc Date: Mon, 20 Feb 2006 13:18:08 +0000 Subject: [PATCH] fix trouble with tkyap (Kerri Harris) git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@1548 b08c6af1-5177-4d33-ba66-4b1c6b8b522a --- C/sysbits.c | 2 +- misc/tkyap | 7 +++++-- pl/consult.yap | 5 ++--- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/C/sysbits.c b/C/sysbits.c index f6021a1ad..f92dc571d 100644 --- a/C/sysbits.c +++ b/C/sysbits.c @@ -1333,7 +1333,7 @@ HandleSIGINT (int sig) my_signal(SIGINT, HandleSIGINT); /* do this before we act */ #if HAVE_ISATTY - if (!isatty(0)) { + if (!isatty(0) && !Yap_sockets_io) { Yap_Error(INTERRUPT_ERROR,MkIntTerm(SIGINT),NULL); } #endif diff --git a/misc/tkyap b/misc/tkyap index 91e6eea29..eeed7f3ae 100644 --- a/misc/tkyap +++ b/misc/tkyap @@ -2,6 +2,9 @@ # tkyap -- a TK shell for YAP # $Locker: $ # $Log: not supported by cvs2svn $ +# Revision 1.1.1.1 2001/04/09 19:53:46 vsc +# Imported sources +# # Revision 1.1 1997/06/02 16:32:00 vsc # Initial revision # @@ -119,7 +122,7 @@ menu .menu.file.m menubutton .menu.exec -text "Execution" -menu .menu.exec.m -underline 0 menu .menu.exec.m .menu.exec.m add command -label "Interrupt" \ - -command {global tcl_mode; set tcl_mode 0; exec kill SIGINT $pid} + -command {global tcl_mode; set tcl_mode 0; exec kill -SIGINT $pid} .menu.exec.m add separator .menu.exec.m add command -label "Statistics" -command {YapStats} @@ -178,7 +181,7 @@ set InputStart [.frame.text index {end - 1 chars}] bind .frame.text { set tcl_mode 0 .frame.text yview -pickplace end - exec kill SIGINT $pid + exec kill -SIGINT $pid } diff --git a/pl/consult.yap b/pl/consult.yap index 00e93acaa..daf23d7b2 100644 --- a/pl/consult.yap +++ b/pl/consult.yap @@ -280,11 +280,10 @@ use_module(M,F,Is) :- '$do_startup_reconsult'(X) :- ( '$access_yap_flags'(15, 0) -> - Opts=[] + '$system_catch'(load_files(X, []),Module,Error,'$Error'(Error)) ; - Opts=[silent(true)] + load_files(X, [silent(true)]) ), - load_files(X, Opts), ( '$access_yap_flags'(15, 0) -> true ; halt). '$skip_unix_comments'(Stream) :-