Re: Regression in sh(1) ? (Was: make delete-old fails when removing catpages)

From: Chet Ramey <chet.ramey_at_case.edu>
Date: Thu, 14 Jan 2010 14:25:49 -0500
On 1/14/10 12:47 PM, Antoine Brodin wrote:

> This seems to be a regression in sh(1).
> Simple test case:
> This succeeds on stable/8:
> %%%
>> sh
> $ touch /tmp/foo; 3<&0; echo /tmp/foo | while read i; do rm -vi ${i} <&3 ; done
> remove /tmp/foo? y
> /tmp/foo
> %%%
> 
> and fails on head:
> %%%
>> sh
> $ touch /tmp/foo; 3<&0; echo /tmp/foo | while read i; do rm -vi ${i} <&3 ; done
> remove /tmp/foo? $ 
> %%%

If these are the actual commands that fail, this is more of a bug fix
than a regression.  The command "3<&0" is not supposed to be equivalent
to "exec 3<&0", and the effects of the redirection should not persist
in the calling shell.

Chet
-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU    chet_at_case.edu    http://cnswww.cns.cwru.edu/~chet/
Received on Thu Jan 14 2010 - 18:41:07 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:40:00 UTC