This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Challenge: a VERY strange problem with command substitution in bash


On Tue, 11 Jul 2017 21:12:14, =?UTF-8?Q?J=c3=bcrgen_Wagner?= wrote:
2. Windows 10, Version 1703, Build 15063.413 on a Dell 64bit platform,
latest 64bit Cygwin (CYGWIN_NT-10.0, 2.8.1(0.312/5/3) 2017-07-03 14:11
x86_64 Cygwin) /bin/bash

$ value=3D"$( date | cat )"; echo "$? <$value>"
127 <>

For what it is worth, I cannot repro this with Windows 7:

   $ value="$( date | cat )"; echo "$? <$value>"
   0 <Tue, Jul 11, 2017  6:16:21 PM>

Also, your example is poor. As you well know, "cat" in this case should be a
noop:

   $ date | cat
   Tue, Jul 11, 2017  6:20:53 PM

Perhaps you can provide a sane example that fails? Something like:

   $ date | sed s/M/Z/
   Tue, Jul 11, 2017  6:21:46 PZ


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]