Subject: [clisp-list] inspector via browser: MS-IE solution

From: "Hoehle, Joerg-Cyril" <[email-masked]>
Date: Wed Mar 19 01:47:02 2003

Hi,

>>            (close (ext:make-pipe-output-stream
>>                    (format nil "\"~A\"~{ ~A~}" (first command) args)))

>are you saying that CloseHandle does not terminate the process on
>win32?!

I'm not saying more than "it works for me". Maybe MS-IE ignores any signal if one is ever sent?

Why should a close terminate a process?

Conceptually, I see a difference between signaling EOF on a pipe and sending a SIGPIPE to cause a program to terminate. That both are mixed is in my POV a UNIXism. It has its uses, e.g. to abort a series | of | pipes | in a shell.

But for some applications, what I needed was: send an application input, then signal that all input is there (typically via EOF, causing a 0 byte read() through a pipe), then let the application perform computations based on this input.
E.g. "cat" may copy its input to some other place. It must not be killed as soon as EOF is seen, since it needs time to save the last bytes.

A SIGKILL coupled to a pipe does not help at all in such a situation.

Please remember to keep process control and EOF separate issues.

BTW, a quick test on Linux (Suse 8.1) with MAKE-PIPE-OUTPUT-STREAM and CLOSE shows that a CLISP child process continues to run after CLOSE.
(make-pipe-output-stream "clisp /.../cat.lisp")

BTW, I forgot how Emacs manages to be able to send multiple EOF (read causes 0-byte read() returns) to a subprocess, like an interactive tty. Obviously, it's not using a simple pipe, since there's place only for a single EOF there: after that is seen, nothing is transmitted any more.

I.e., there's a difference between
		clisp cat.lisp
and		tee input.log | clisp cat.lisp
w.r.t. the ability to use ^D in the debugger.

Regards,
	Jorg Hohle.

---

From: Randall R Schulz <[email-masked]>
Date: Wed Mar 19 07:03:02 2003

Joerg,

At 01:44 2003-03-19, Hoehle, Joerg-Cyril wrote:
>...

Under Unix (and Unix work-alikes) SIGKILL cannot be caught or ignored, 
so it is singularly useless for anything except unconditional, abrupt 
and abortive termination.

>...

Randall Schulz