Subject: Re: [clisp-list] (ext:run-program) newbie having problems

From: "M.K." <[email-masked]>
Date: Sat Jun 28 21:00:18 2003

Yes, that is it.

$ cat|ftp|cat also proves this...

I wonder if there is a way to trick ftp into thinking it is talking to a pty
when (run-program) does it's job?

Thanks & Cheers, M.K.

---

At 12:57 PM 6/29/03 +1000, you wrote:
>Hello M.K.,
>
>Saturday, June 28, 2003, 4:18:57 PM, you wrote:
>
>
>> Hi, I am having trouble reading from the I/O stream created when I run
>> /bin/ftp on my linux system. This is what I am doing:
>
>> (setq iostm (ext:run-program "/bin/ftp" :input :stream :output :stream))
>
>iostm =>> #<IO TWO-WAY-STREAM>
>
>> When I try to (read-char iostm) it just hangs. Given that the ftp program
>> normally presents stdout with the prompt "ftp> ", I was expecting to see #\f
>> as the first char.
>I think ftp program detects whether its input stream is terminal and
>prints a prompt only if it is. Try this:
>
>file zz1:
>help
>quit
>
>ftp < zz1 > zz2
>
>results in file zz2 without any prompts in it.
>
>-- 
>Best regards,
> Arseny    
>
>
>