Steve, First off, this patch does fix the large paste problem. Thanks for this!
However, there are a couple of problems with this patch. For example, this makes bash run from a command prompt (or a shortcut) treat every character as a ^D. Bash run from an xterm/rxvt works fine. /bin/sh ignores Enter (or ^J, or ^M). Running 'bash -c "echo BLAH && exit"' from a command prompt works, however, running "bash -c 'echo BLAH && exit' results in C:\cygwin\bin>bash -c 'echo BLAH && exit' BLAH 'exit'' is not recognized as an internal or external command, operable program or batch file. C:\cygwin\bin> and "bash -c 'echo BLAH && exit '" (with a space after exit) echoes BLAH and exits the originating command prompt. Putting any character after the space results in the same behavior. I'm attaching an strace of bash running under command with this problem. Adding 'tty' to CYGWIN doesn't affect the outcome. Setting TERM to 'cygwin' in xterm/rxvt doesn't reproduce the problem - this only happens in a command shell. I'm unable to track this down further. Hope this helps. Please let me know if you need any additional info. Igor On Fri, 18 Oct 2002, Steve O wrote: > Hi, > > This patch solves some deadlock issues which would prevent > terminal programs such as rxvt and xterm from being able > to handle large pastes or cat binary files. > > The fix involves two mechanisms, adding a buffer for > termios echoing, and allowing a pty_master write to > write less than the entire buffer. > > There is one small bug remaining that I know of. When the > pty_slave changes from cooked to raw, the master doesn't seem to > know to flush the line edit buffer until a key is pressed. > Should be an easy fix, but I'm not sure how to best do it. > > -steve -- http://cs.nyu.edu/~pechtcha/ |\ _,,,---,,_ [EMAIL PROTECTED] ZZZzz /,`.-'`' -. ;-;;,_ [EMAIL PROTECTED] |,4- ) )-,_. ,\ ( `'-' Igor Pechtchanski '---''(_/--' `-'\_) fL a.k.a JaguaR-R-R-r-r-r-.-.-. Meow! "Water molecules expand as they grow warmer" (C) Popular Science, Oct'02, p.51
steve_o-paste-bash.strace.bz2
Description: Binary data