From owner-freebsd-bugs Mon Mar 13 03:00:10 1995 Return-Path: bugs-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id DAA02285 for bugs-outgoing; Mon, 13 Mar 1995 03:00:10 -0800 Received: (from gnats@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id DAA02272; Mon, 13 Mar 1995 03:00:07 -0800 Date: Mon, 13 Mar 1995 03:00:07 -0800 Message-Id: <199503131100.DAA02272@freefall.cdrom.com> From: candy@kgc.co.jp Reply-To: candy@kgc.co.jp To: freebsd-bugs Subject: bin/241: strange behavior of /bin/sh In-Reply-To: Your message of Mon, 13 Mar 1995 12:58:54 +0900 <199503130358.MAA08766@xxx.kgc.co.jp> Sender: bugs-owner@FreeBSD.org Precedence: bulk >Number: 241 >Category: bin >Synopsis: strange behavior of /bin/sh >Confidential: no >Severity: serious >Priority: low >Responsible: freebsd-bugs (FreeBSD bugs mailing list) >State: open >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Mar 13 03:00:03 1995 >Originator: candy@kgc.co.jp (Toshihiro Kanda) >Organization: Keisokugiken corp. >Release: FreeBSD 2.0-RELEASE i386 >Environment: >Description: It seems /bin/sh handles `&' operator inside for loop incorrectly. >How-To-Repeat: $ cat foo for i in a b c; do xx=${xx}${i} echo $xx xx=${xx}${i} echo $xx & xx=${xx}${i} echo $xx done $ sh foo a ab abc a aa ab abb abc abcc # This should be a aaa aaab aaabbb aaabbbc aaabbbccc aa aaabb aaabbbcc >Fix: I don't know, but it seems /bin/sh of NetBSD 1.0 works well. >Audit-Trail: >Unformatted: