Олег Белозеров writes:
> Richard M Kreuter <kreuter@...> writes:
> > Output to Lisp streams is fully buffered by default in SBCL. Most Unix
> > programs buffer output to non-terminal output devices, too. Do you ever
> > flush output to the coprocess? Are you convinced that the coprocess
> > also flushes output?
> Yes, I did FINISH-OUTPUT after each WRITE-LINE and fflush(stdout) at C
> side. Sorry for not mentioning it in previous message.
A few guesses:
* What platform are you on? If it's Windows, there are some flaws in
streams there that affect RUN-PROGRAM.
* Does the coprocess want to interact with the user via the tty? ISTR a
discussion about RUN-PROGRAM not doing some requisite process
group/session/job control mumbojumbo. (I'm blanking on the details,
* It's conceivable that either SBCL or the coprocess isn't happy with
the data passing back and forth. For example, SBCL doesn't currently
support line terminations other than #\Linefeed; if the coprocess
terminates output lines with #\Return for some reason, READ-LINE will
treat all of the coprocess's output as one long line, and so will hang
(but not block). Have you tried doing I/O to the coprocess with
READ-CHAR/WRITE-CHAR and/or READ-BYTE/WRITE-BYTE?
Finally, are you able to share (privately or publically) at least the
I/O parts of your C program?