www.delorie.com/archives/browse.cgi | search |
Message-Id: | <201707112325.v6BNP5pw009048@delorie.com> |
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:date:to:from:reply-to:subject:in-reply-to | |
:references:mime-version:content-type:content-transfer-encoding; | |
q=dns; s=default; b=dIYHyZ0qb+rdw1xYIaLbsEU1gRURCvNjuDP0ivtKPvt | |
JMVXQ12P3TYEQDs7V1U/WKrcouAXTPy0YI8R0OJaPLza14OaVG4pExddpoKtp9oM | |
ecf7ynyI2hSEiMI/Fs+mKP+KlMpHaCf/xbI7E6y9o7X6xUGxlX5TiDsFggTMPjnA | |
= | |
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:date:to:from:reply-to:subject:in-reply-to | |
:references:mime-version:content-type:content-transfer-encoding; | |
s=default; bh=lnyKway9xrC82GEaBsb5bvfa4MU=; b=qFojhlURi1lJpPJ36 | |
jrW8PxQM13gIQ5XIdk6wqa5ivthOU5RjeZoHiOdudKqgNY80VI3VzBDbUmZVTLO3 | |
4/PQAqTgg4d3iKVy2hUOH3JURbpGoJLkfBIr8L3KKdBL7cD0fkGXPm7wZVsS23tU | |
O/2JQlaKmeUZcevVplcGkqc+8M= | |
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=3.8 required=5.0 tests=AWL,BAYES_50,FORGED_YAHOO_RCVD,FREEMAIL_FROM,MISSING_MID,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_NEUTRAL autolearn=no version=3.3.2 spammy=puzzled, swear, intrusion, Hx-languages-length:2518 |
X-HELO: | resqmta-po-08v.sys.comcast.net |
Date: | Tue, 11 Jul 2017 19:22:33 -0400 |
To: | cygwin AT cygwin DOT com |
From: | "Richard Beels via cygwin" <cygwin AT cygwin DOT com> |
Reply-To: | Richard Beels <rbeels AT yahoo DOT com> |
Subject: | Re: Challenge: a VERY strange problem with command substitution in bash |
In-Reply-To: | <93b0a4e1-78eb-798e-9946-cd38ab288cce@wagner.is> |
References: | <93b0a4e1-78eb-798e-9946-cd38ab288cce AT wagner DOT is> |
Mime-Version: | 1.0 |
X-CMAE-Envelope: | MS4wfK+Fii08phzpvOdZ0gQs6rtzEK5ISVch7z1ltg52hyiSAQqyHKLzsxkbkWVrEGALXmc7dYUnF+HFBKzJNuFNyosUbPC+Wh69gNGmxqRm99qK1fzsSUei JXkxeFMXVyW9KaetsoZsulnyZNkP9AfdNmpNbAxfEOaaQf6zEBzdnyg9ao5XBk4EfUpls6GH2vdtTg== |
X-IsSubscribed: | yes |
X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id v6BNP5pw009048 |
At 07/11/2017 at 15:12, Shakespearean monkeys danced on Jürgen Wagner's keyboard and said: >... >Using backquotes instead of the command >substitution with $(...) does not change the >results. I could swear this did work in an >earlier version of Cygwin on my Windows 7 machine. > >I tried this to see if the code in the parentheses is executed at all: > >$ value="$( date 2> foo | cat )"; echo "$? <$value>" > >The file "foo" was not created, i.e., it seems >the commands don't really get executed. > >$ value="$( date && pwd )"; echo "$? <$value>" >0 <Tue Jul 11 20:49:09 CEST 2017 >/home/juergen> > >$ value="$( date || pwd )"; echo "$? <$value>" >0 <Tue Jul 11 20:32:27 CEST 2017> > >both work, so some control structures seem to be >permissible... just not a pipe. > >What is going on? Some misconfiguration? A >Cygwin bug? Some interaction with something >weird in Windows 10? I am at loss to understand >what could be wrong... and am now most curious >whether anybody has an idea what is causing >this. Does it work/not work in the same way in your Cygwin installation? > >I came across this effect because >ssh-host-config did not recognize me as >administrator anymore. It's due to a check for a >certain user group that uses a command >substitution with a pipe. Replacing this with an >equivalent command works. The original line used >"id -G" and then a "grep -Eq" to check whether a certain group is on that list. > >I am VERY curious now! I've rarely been puzzled >that much by such a very elementary shell >expression (looking back at 34 years of Unix experience). Hi Jurgen. 90% chance it's what is called bloda in these parts. It's in the FAQ on cygwin.com. I'll go out on a limb and say you might have just installed/changed your AV/Firewall software. And if I want to be super-psychic, can I guess comodo? Because I just changed to comodo a couple weeks ago and had the same subshell/command substitution/pipeline errors you're mentioning. If so, you need to exclude your cygwin folder from AV scanning. AND... if the software does whitelisting or host intrusion protection (HIPS) or "run unknown executables in a container/sandbox" or something similar, you also need to trust all the executables, too. Or switch to something else that doesn't trip cygwin's trigger. After doing that and a rebaseall, I haven't had a fork error in a week. I can't wait to run setup and come up with an update process, though... Cheers! -- 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
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |