Help me understand why 'eof' in canonical mode works strange in Expect script (and differ from Linux).

2011-09-16 Thread Oleksandr Gavenko
This script work fine: $ cat eof.exp #!/usr/bin/env expect set stty_init sane cooked -echo spawn sort send \x04 expect eof wait But if I modify send expression to any like (so ^D is last char): send bo\x04 script infinitely await closing stdout by sort, but sort itself wait for

Re: Help me understand why 'eof' in canonical mode works strange in Expect script (and differ from Linux).

2011-09-16 Thread Eric Blake
On 09/16/2011 03:28 PM, Oleksandr Gavenko wrote: This script work fine: But if I modify send expression to any like (so ^D is last char): send bo\x04 script infinitely await closing stdout by sort, but sort itself wait for closing stdin, which not happen. This is not cygwin-specific. On