picolisp

Unnamed repository; edit this file to name it for gitweb.
git clone https://logand.com/git/picolisp.git/
Log | Files | Refs | README | LICENSE

commit 159cf31388f881c3c827a15901d4217635056035
parent 8862b4a533da571d839c333932be111c276dbc64
Author: Commit-Bot <unknown>
Date:   Sat,  4 Sep 2010 10:51:01 +0000

Automatic commit from picoLisp.tgz, From: Sat, 04 Sep 2010 10:51:01 GMT
Diffstat:
Mlib/tags | 12++++++------
Msrc/flow.c | 12+++++++-----
Msrc64/flow.l | 21++++++++++++++-------
Msrc64/version.l | 4++--
4 files changed, 29 insertions(+), 20 deletions(-)

diff --git a/lib/tags b/lib/tags @@ -46,7 +46,7 @@ bool (1743 . "@src64/flow.l") box (841 . "@src64/flow.l") box? (999 . "@src64/sym.l") by (1553 . "@src64/apply.l") -bye (3446 . "@src64/flow.l") +bye (3453 . "@src64/flow.l") caaaar (271 . "@src64/subr.l") caaadr (288 . "@src64/subr.l") caaar (99 . "@src64/subr.l") @@ -138,7 +138,7 @@ flip (1686 . "@src64/subr.l") flush (4916 . "@src64/io.l") fold (3343 . "@src64/sym.l") for (2247 . "@src64/flow.l") -fork (3269 . "@src64/flow.l") +fork (3276 . "@src64/flow.l") format (2089 . "@src64/big.l") free (2024 . "@src64/db.l") from (3371 . "@src64/io.l") @@ -165,12 +165,12 @@ inc (2256 . "@src64/big.l") index (2611 . "@src64/subr.l") info (2681 . "@src64/main.l") intern (875 . "@src64/sym.l") -ipid (3214 . "@src64/flow.l") +ipid (3221 . "@src64/flow.l") isa (978 . "@src64/flow.l") job (1448 . "@src64/flow.l") journal (967 . "@src64/db.l") key (3202 . "@src64/io.l") -kill (3246 . "@src64/flow.l") +kill (3253 . "@src64/flow.l") last (2031 . "@src64/subr.l") length (2687 . "@src64/subr.l") let (1498 . "@src64/flow.l") @@ -234,7 +234,7 @@ on (1583 . "@src64/sym.l") onOff (1613 . "@src64/sym.l") one (1646 . "@src64/sym.l") open (4143 . "@src64/io.l") -opid (3230 . "@src64/flow.l") +opid (3237 . "@src64/flow.l") opt (2967 . "@src64/main.l") or (1659 . "@src64/flow.l") out (4037 . "@src64/io.l") @@ -318,7 +318,7 @@ tail (1898 . "@src64/subr.l") tell (3125 . "@src64/io.l") text (1272 . "@src64/sym.l") throw (2510 . "@src64/flow.l") -tick (3182 . "@src64/flow.l") +tick (3189 . "@src64/flow.l") till (3438 . "@src64/io.l") time (2491 . "@src64/main.l") touch (1049 . "@src64/sym.l") diff --git a/src/flow.c b/src/flow.c @@ -1,4 +1,4 @@ -/* 22jun10abu +/* 04sep10abu * (c) Software Lab. Alexander Burger */ @@ -1533,7 +1533,6 @@ any doCall(any ex) { flushAll(); if ((pid = fork()) == 0) { setpgid(0,0); - tcsetpgrp(0,getpgrp()); execvp(av[0], av); execError(av[0]); } @@ -1543,7 +1542,8 @@ any doCall(any ex) { if (pid < 0) err(ex, NULL, "fork"); setpgid(pid,0); - tcsetpgrp(0,pid); + if (Termio) + tcsetpgrp(0,pid); for (;;) { while (waitpid(pid, &res, WUNTRACED) < 0) { if (errno != EINTR) @@ -1551,11 +1551,13 @@ any doCall(any ex) { if (*Signal) sighandler(ex); } - tcsetpgrp(0,getpgrp()); + if (Termio) + tcsetpgrp(0,getpgrp()); if (!WIFSTOPPED(res)) return res == 0? T : Nil; load(NULL, '+', Nil); - tcsetpgrp(0,pid); + if (Termio) + tcsetpgrp(0,pid); kill(pid, SIGCONT); } } diff --git a/src64/flow.l b/src64/flow.l @@ -1,4 +1,4 @@ -# 22jun10abu +# 04sep10abu # (c) Software Lab. Alexander Burger (code 'redefMsgEC) @@ -3131,8 +3131,6 @@ nul4 # In child? if z # Yes cc setpgid(0 0) # Set process group - cc getpgrp() # Set terminal process group - cc tcsetpgrp(0 A) cc execvp((S) S) # Execute program jmp execErrS # Error if failed end @@ -3144,7 +3142,10 @@ until z # Yes ld Z A # Keep pid in Z cc setpgid(Z 0) # Set process group - cc tcsetpgrp(0 Z) # Set terminal process group + null (Termio) # Raw mode? + if nz # Yes + cc tcsetpgrp(0 Z) # Set terminal process group + end do # Re-use expression stack entry do cc waitpid(Z S WUNTRACED) # Wait for child @@ -3158,8 +3159,11 @@ call sighandlerX end loop - cc getpgrp() # Set terminal process group - cc tcsetpgrp(0 A) + null (Termio) # Raw mode? + if nz # Yes + cc getpgrp() # Set terminal process group + cc tcsetpgrp(0 A) + end call wifstoppedS_F # WIFSTOPPED(S)? if ne # No ld4 (S) # Result? @@ -3174,7 +3178,10 @@ ld B (char "+") # Prompt ld E Nil # REPL call loadBEX_E - cc tcsetpgrp(0 Z) # Set terminal process group + null (Termio) # Raw mode? + if nz # Yes + cc tcsetpgrp(0 Z) # Set terminal process group + end cc kill(Z SIGCONT) loop diff --git a/src64/version.l b/src64/version.l @@ -1,6 +1,6 @@ -# 31aug10abu +# 04sep10abu # (c) Software Lab. Alexander Burger -(de *Version 3 0 3 17) +(de *Version 3 0 3 18) # vi:et:ts=3:sw=3