From owner-freebsd-bugs Thu Aug 1 11:20:10 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 276ED37B401 for ; Thu, 1 Aug 2002 11:20:03 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4C20943E5E for ; Thu, 1 Aug 2002 11:20:02 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g71IK2JU026888 for ; Thu, 1 Aug 2002 11:20:02 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g71IK2cv026887; Thu, 1 Aug 2002 11:20:02 -0700 (PDT) Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2634137B400 for ; Thu, 1 Aug 2002 11:10:51 -0700 (PDT) Received: from coe.ufrj.br (roma.coe.ufrj.br [146.164.53.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1826743E42 for ; Thu, 1 Aug 2002 11:10:49 -0700 (PDT) (envelope-from jonny@jonny.eng.br) Received: by coe.ufrj.br (Postfix, from userid 2000) id 374A0D9233; Thu, 1 Aug 2002 15:10:39 -0300 (BRT) Message-Id: <20020801181039.374A0D9233@coe.ufrj.br> Date: Thu, 1 Aug 2002 15:10:39 -0300 (BRT) From: Joao Carlos Mendes Luis Reply-To: Joao Carlos Mendes Luis To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Subject: bin/41240: /bin/sh builtins redirection failures abort entire script Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org >Number: 41240 >Category: bin >Synopsis: /bin/sh builtins redirection failures abort entire script >Confidential: no >Severity: serious >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Aug 01 11:20:01 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Joao Carlos Mendes Luis >Release: FreeBSD 4.6-STABLE i386 >Organization: COPPE/UFRJ >Environment: System: FreeBSD roma.coe.ufrj.br 4.6-STABLE FreeBSD 4.6-STABLE #0: Tue Jul 9 16:08:41 BRT 2002 jonny@roma.coe.ufrj.br:/usr/cvsup/RELENG_4/src/sys/compile/ROMA i386 4-stable from July, 29, 2002 >Description: See example below >How-To-Repeat: This script fails with /bin/sh, works with bash #! /bin/sh TestFunc() { ${ECHO} "no perm" > $file # Builtin echo does not reach here ${ECHO} ok ${ECHO} "no perm" >> $file ${ECHO} ok } file=/tmp/xxx touch $file chmod 000 $file ECHO=/bin/echo TestFunc ECHO=echo TestFunc >Fix: >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message