X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-6.7 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_HI,SPF_HELO_PASS,TW_PD,TW_YG,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Message-ID: <4D5C318F.6030604@redhat.com> Date: Wed, 16 Feb 2011 13:20:31 -0700 From: Eric Blake User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.13) Gecko/20101209 Fedora/3.1.7-0.35.b3pre.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.7 MIME-Version: 1.0 To: cygwin AT cygwin DOT com Subject: Re: echo $(cygcheck...) oddity References: <4D5C127D DOT 40401 AT member DOT fsf DOT org> <4D5C13D1 DOT 8010105 AT redhat DOT com> In-Reply-To: OpenPGP: url=http://people.redhat.com/eblake/eblake.gpg Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="------------enig338D679F562305E25096C54E" X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com --------------enig338D679F562305E25096C54E Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On 02/16/2011 01:06 PM, RISINGP1 AT nationwide DOT com wrote: > I suspected a problem with \r, so I tried it. However, I am using pdksh,= =20 > and ended up with something that really was unexpected... No, that's also expected. pdksh echo obeys POSIX by default. Bash echo does not. Echo and backslash is a non-portable combination (POSIX itself recommends using printf if you suspect that you might be printing a backslash, because it requires the pdksh behavior but so many people have come to expect the bash behavior). Since cygcheck output includes backslashes, you should not expect any sensible behavior when trying to echo it, and should instead use printf. --=20 Eric Blake eblake AT redhat DOT com +1-801-349-2682 Libvirt virtualization library http://libvirt.org --------------enig338D679F562305E25096C54E Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/ iQEcBAEBCAAGBQJNXDGPAAoJEKeha0olJ0Nqh+AH/RQypWqebmb1BQneQaM7I1S1 Jp+mlNbiqnA4K/MRYYmoZ2WWj7ub+tPGTJZfi3Fsx9CPdxKl6AFpaUcqX8w4+aQF 0T9AY3L4wXc803ikgTqPVdr9+ASEbRoYT2BgB9vIIX23UvCD/pfAk/D+ixH9vXNm 2jALsYNwI6ZQ5XBsZ1jaiDGF+zqVakZMbjG2pvDtWhABJZycfYmGz576OwMdocjM 4KWsw/LMkJrn1p9NIv+RgpIcsN23LtMOn38Fm3Mmv8ZJB3/FTlA6E0dCH4wUFlm/ c3XmTwkf4/nsa8jWboTpPMMZ7M91XCWzjua6JB1Ctw8VkrBYSO0y/N4SAwiEQ5k= =xmHI -----END PGP SIGNATURE----- --------------enig338D679F562305E25096C54E--