On 03/20/2016 11:49 AM, Chet Ramey wrote: > On 3/20/16 12:54 AM, Жанна Целых wrote: > >> uname output: CYGWIN_NT-6.1 microsoft-win7 2.4.1(0.293/5/3) 2016-01-24 >> 11:24 i686 Cygwin >> Machine Type: i686-pc-cygwin >> >> Bash Version: 4.3 >> Patch Level: 42 >> Release Status: release >> >> Description: >> In bash-4.3-p42 from Cygwin read builtin ignores some bytes after >> CR-byte. > > It may be the setmode() call in the read builtin, but that's been there > forever. > > I don't use cygwin or test on it. You'll probably have better luck filing > a bug report with the cygwin folks.
I'm testing what happens if the setmode() call is removed in my next build of bash for cygwin; I can't figure out why text mode would be desirable in the first place, but even if it is desirable, it should only eat \r immediately before \n, not \r before other bytes. This may be stale leftover code from years ago that doesn't make sense to keep around. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature