Path: csiph.com!goblin1!goblin.stu.neva.ru!usenet.stanford.edu!not-for-mail From: Valentin Lab Newsgroups: gnu.bash.bug Subject: process substitution bug or difference from bash 4.4 Date: Wed, 25 Mar 2020 15:35:57 +0100 Lines: 45 Approved: bug-bash@gnu.org Message-ID: References: NNTP-Posting-Host: lists.gnu.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: usenet.stanford.edu 1585148423 1375 209.51.188.17 (25 Mar 2020 15:00:23 GMT) X-Complaints-To: action@cs.stanford.edu To: bug-bash@gnu.org Envelope-to: bug-bash@gnu.org X-Virus-Scanned: Debian amavisd-new at kal.fr DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kalysto.org; s=default; t=1585146958; bh=OH3C/E6x29RhhfCySM5mvRWbFzbXOIQA7Quno6FTuRE=; h=To:From:Subject:Date:From; b=jQH+Pn8lGNS2W4PXq31vpidOK4RFsHZtjO11KZ7+sb/n0PyJZ9flU1qvKkF8Kf1Lb beA2r3Oks7GskzkF9UNx9dLjcVLVbuAMLPNDNKTeUc3blhKR0UJTElOUzZIL8polj2 Tvn0M1Fw2HO8mzPvGSM4UHLklEfhukVRUOw8CUho= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 Content-Language: en-US X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 149.202.204.141 X-Mailman-Approved-At: Wed, 25 Mar 2020 11:00:21 -0400 X-BeenThere: bug-bash@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Bug reports for the GNU Bourne Again SHell List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Mailman-Original-Message-ID: Xref: csiph.com gnu.bash.bug:16041 Hi, I have encountered an issue when running some bash code from 4.4 on a bash 5 ... I've managed to pinpoint the exact issue on my end. Here are 2 functions that are quite similar, except the usage of "{ ; }" around the "cat": ## ---------------- ouch() { cat < <(echo bar) cat "$1" } ouch2() { { cat; } < <(echo bar) cat "$1" } ##---------------- Runnning this will give the same output on bash 4.4 and 5: $ ouch <(echo "foo") foo bar And by replacing "ouch" by "ouch2", I have the same output in bash 4.4 . But running it on bash 5 will fail: $ ouch2 <(echo "foo") bar cat: /dev/fd/63: No such file or directory Is that expected ? I'd be happy to know about the rationale behind this (and the change) if this is expected. Many thanks, Valentin Lab