[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
How to flush output to process
From: |
Frank Fischer |
Subject: |
How to flush output to process |
Date: |
Sun, 6 Nov 2011 09:53:39 +0000 (UTC) |
User-agent: |
slrn/0.9.9p1 (Linux) |
Hi,
I have a question about communication with processes. I want to start
an external program from Emacs Lisp in a process (using
`start-file-process'). This program accepts input data from stdin and
writes its results to stdout. After sending data to the process using
`process-send-string' nothing happens if the data does not end in a
newline character. The problem is that in general I cannot end every
request I send to the process with a newline (a constraint of the
communication protocol) and using `process-send-eof' is also not an
option because this seems to close the connection completely (I want
to communicate with the process in several turns).
In something like C I would use fflush(...) to force the buffered data
to be sent to the process (and it works), but I have not been able to
find some comparable function for Emacs Lisp.
Is there a way the flush the Emacs->process stream, i.e., force all
buffered data to be actually send to the process, from Emacs Lisp?
Thanks in advance,
Frank
- How to flush output to process,
Frank Fischer <=
- Re: How to flush output to process, Eli Zaretskii, 2011/11/06
- Re: How to flush output to process, Frank Fischer, 2011/11/06
- Re: How to flush output to process, Thien-Thi Nguyen, 2011/11/06
- Re: How to flush output to process, Frank Fischer, 2011/11/06
- Re: How to flush output to process, Thien-Thi Nguyen, 2011/11/07
- Re: How to flush output to process, Frank Fischer, 2011/11/07
- Re: How to flush output to process, Thien-Thi Nguyen, 2011/11/07
- Re: How to flush output to process, Frank Fischer, 2011/11/09