[EMAIL PROTECTED] (Bj�rn Lindberg) writes:

> I have some difficulties with RUN-PROGRAM. It sometimes hangs when
> using the :output :stream key parameter. I thought I had it traced
> down to when a program only has output on stderr and not on stdout,
> but that is not quite right either:
... 
> At the places where I interrupt it, it is because it hangs, and
> nothing happens. What is really strange is that giving -h or -1 (one)
> as arguments seem to work, whereas -l (small L) makes it hang. If it
> returns, reading from the output stream is not a problem. If I remove
> the :output key argument, it does not hang either.

It sounds like it's deadlocking because ls wants to output to the
stream, but the stream's buffer is full.  ls -l would produce more
output than -h or -1 in most cases.  So you can probably pass :wait
NIL to RUN-PROGRAM so that it returns before ls has exited, and read
from the stream so ls can finish writing.

> Oh, and running the same commands at the shell prompt works of course,
> and the output and exit status is similar.
> 
> 
> Bj�rn
> 

-- 
-Tim



Reply via email to