| delorie.com/archives/browse.cgi | search |
| X-Recipient: | archive-cygwin AT delorie DOT com |
| DomainKey-Signature: | a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id |
| :list-unsubscribe:list-subscribe:list-archive:list-post | |
| :list-help:sender:subject:to:references:from:message-id:date | |
| :mime-version:in-reply-to:content-type; q=dns; s=default; b=dgdM | |
| zlk7KGIPjLymxAD1Kij0rT6p/IOjyV0//AA0H36jDeFbA8YIa77MZ9pb6jc2G/fs | |
| xbNx8RUEWCHvWJmR+1aYdaWrrtHAMF/Q5TuFgkTV3VWx/ksfeFCIKHqqXy3YJo9j | |
| VDPdhV0GNNskLGng+3tivsJpBR9wwwN6cOLULS8= | |
| DKIM-Signature: | v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id |
| :list-unsubscribe:list-subscribe:list-archive:list-post | |
| :list-help:sender:subject:to:references:from:message-id:date | |
| :mime-version:in-reply-to:content-type; s=default; bh=6DycvgTAOf | |
| M/2FDYRYBnoXndV1w=; b=EZzfDTx8yvxzcpafC2R8LwFUvs361uL33uF51lwE8J | |
| 2/KLUXtvb953U/syaJm9i3EilVjU0ac7yg+FZJZpFtf5Esf48+nvYTPyCUQ4f17k | |
| 4SCdloJhZwW8HRS0B/aSqpobl0fwFroa5TK3YKkn4O9POucxhlYJix2vYFXbDHBT | |
| k= | |
| Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
| List-Id: | <cygwin.cygwin.com> |
| List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
| List-Archive: | <http://sourceware.org/ml/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
| Sender: | cygwin-owner AT cygwin DOT com |
| Mail-Followup-To: | cygwin AT cygwin DOT com |
| Delivered-To: | mailing list cygwin AT cygwin DOT com |
| Authentication-Results: | sourceware.org; auth=none |
| X-Virus-Found: | No |
| X-Spam-SWARE-Status: | No, score=-1.3 required=5.0 tests=AWL,BAYES_00,KAM_LAZY_DOMAIN_SECURITY,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=no version=3.3.2 |
| X-HELO: | mx1.redhat.com |
| Subject: | Re: [Bug] bash' read builtin command behaves differently on '\r' (4.3.33) |
| To: | cygwin AT cygwin DOT com, Jeff Downs <heydowns AT somuchpressure DOT net> |
| References: | <20150514223211 DOT 790926b378d251d4b25dc82b AT nm DOT ru> |
| From: | Eric Blake <eblake AT redhat DOT com> |
| Openpgp: | url=http://people.redhat.com/eblake/eblake.gpg |
| Message-ID: | <56042B11.3060201@redhat.com> |
| Date: | Thu, 24 Sep 2015 10:55:45 -0600 |
| User-Agent: | Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 |
| MIME-Version: | 1.0 |
| In-Reply-To: | <20150514223211.790926b378d251d4b25dc82b@nm.ru> |
| X-IsSubscribed: | yes |
--Bt7HBBKf5xfilVsAMVomG6wWjFmkmg642
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
On 05/14/2015 01:32 PM, Mikhail Usenko wrote:
>=20
> Cygwin version: 2.0.2-1
>=20
> [linux]$ bash --version
> GNU bash, version 4.3.33(1)-release (i686-redhat-linux-gnu)
> [cygwin]$ bash --version
> GNU bash, version 4.3.33(1)-release (x86_64-unknown-cygwin)
>=20
> Testcase:
> [linux]$ echo -ne "\r\n" | { read t; echo "$t"; } | od -A n -t x1
> 0d 0a
> [cygwin]$ echo -ne "\r\n" | { read t; echo "$t"; } | od -A n -t x1
> 0a
>=20
> But then, the pipe itself is OK:
> [cygwin]$ echo -e "\r" | od -A n -t x1
> 0d 0a
Jeff Downs helped me investigate off-list, and I think he found the
culprit (a typo in input.c that requested O_TEXT when it meant B_TEXT,
when mapping from open() flags to bash's internal B_* flags). I'm
building a new bash build right now, and will shortly be posting it for
testing.
--=20
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
--Bt7HBBKf5xfilVsAMVomG6wWjFmkmg642
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
Comment: Public key at http://people.redhat.com/eblake/eblake.gpg
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/
iQEcBAEBCAAGBQJWBCsRAAoJEKeha0olJ0NqqOIH/iBxcOUJlRl2CE0hKeKuHkcO
pn2DIBECzxm9LeTZ7JIvFWhPkibKYCcRPK/5APs5ptOmLRn8dD35Jcm5bvKarYN9
BIQrQosh98wuC2HDdYxMv4NvWIJZYESVtZK5aaunTPJ0kWKRV6vWg3WSOxKi3tBJ
sC0/b2ISvYtA9188NnekrIUMlCv8AtZIdId0bDupiPhkAnyUglT0SherrHxDto6C
xVxDMwJ2pjSRmYzttwpojD1xQSq8CMHNWaBj9gf6GXYVRyuaYs/PDlNgrZmRJyRr
sn0tUPpgr80xhkAWaeDXCOqZbOg7+/nGt9P903WQKDnPWhZUtARa/TsP81q9798=
=Vb7T
-----END PGP SIGNATURE-----
--Bt7HBBKf5xfilVsAMVomG6wWjFmkmg642--
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |