NetBSD Problem Report #11317
Received: (qmail 9171 invoked from network); 26 Oct 2000 15:24:08 -0000
Message-Id: <200010261520.e9QFKjX01893@rfhpc8321.fh-regensburg.de>
Date: Thu, 26 Oct 2000 17:20:45 +0200 (MEST)
From: Hubert Feyrer <feyrer@rfhpc8321.fh-regensburg.de>
Reply-To: hubert.feyrer@rz.uni-regensburg.de
To: gnats-bugs@gnats.netbsd.org
Subject: /bin/sh ignores unbalanced ) in ``s
X-Send-Pr-Version: 3.95
>Number: 11317
>Category: bin
>Synopsis: /bin/sh ignores unbalanced ) in ``s
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Oct 26 15:25:01 +0000 2000
>Closed-Date: Fri Nov 07 15:42:42 +0000 2008
>Last-Modified: Fri Nov 07 15:42:42 +0000 2008
>Originator: Hubert Feyrer
>Release: 3.0 (tested), originally submitted for netbsd-1-5 20001026
>Organization:
>Environment:
System:
* NetBSD yui.fh-regensburg.de 3.0_STABLE NetBSD 3.0_STABLE (YUI) #1: Sat Mar 25 23:30:57 MET 2006 feyrer@yui.fh-regensburg.de:/usr/cvs/src-3/sys/arch/i386/compile/YUI i386
* NetBSD noon 1.5_ALPHA2 NetBSD 1.5_ALPHA2 (NOON) #52: Sun Oct 8 23:03:52 MEST 2000 feyrer@noon:/usr/cvs/src-1.5/sys/arch/i386/compile/NOON i386
>Description:
Our /bin/sh seems to ignore any unbalanced trailing ')'s in
expressions evaluated in ``s. (memalloc.c,v 1.21.10.1)
>How-To-Repeat:
noon% sh
$ echo `date )))`
Thu Oct 26 17:16:49 MEST 2000
$ echo `date)))`
Thu Oct 26 17:16:58 MEST 2000
$ echo `date)`
Thu Oct 26 17:17:03 MEST 2000
$
>Fix:
No clue.
The same thing on solaris:
rfhpc8317% sh
$ echo `date )))`
syntax error: `)' unexpected
$ echo `date)))`
syntax error: `)' unexpected
$ echo `date)`
syntax error: `)' unexpected
$
(same for ksh)
>Release-Note:
>Audit-Trail:
From: Christos Zoulas <christos@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/11317 CVS commit: src/bin/sh
Date: Wed, 5 Nov 2008 22:04:43 +0000 (UTC)
Module Name: src
Committed By: christos
Date: Wed Nov 5 22:04:43 UTC 2008
Modified Files:
src/bin/sh: parser.c
Log Message:
PR/11317: Hubert Feyrer: Recognize mismatched parentheses inside old style
command substitution.
To generate a diff of this commit:
cvs rdiff -r1.69 -r1.70 src/bin/sh/parser.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->closed
State-Changed-By: christos@NetBSD.org
State-Changed-When: Wed, 05 Nov 2008 17:14:31 -0500
State-Changed-Why:
fixed, thanks
State-Changed-From-To: closed->open
State-Changed-By: christos@NetBSD.org
State-Changed-When: Fri, 07 Nov 2008 10:09:54 -0500
State-Changed-Why:
simply counting parentheses does not work. We need to properly parse the
code to handle case statements etc.
From: Christos Zoulas <christos@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/11317 CVS commit: src/bin/sh
Date: Fri, 7 Nov 2008 15:08:43 +0000 (UTC)
Module Name: src
Committed By: christos
Date: Fri Nov 7 15:08:43 UTC 2008
Modified Files:
src/bin/sh: parser.c
Log Message:
Break PR/11317 again. The counting parentheses fix does not handle case
statements properly. Fixes PR/39873.
To generate a diff of this commit:
cvs rdiff -r1.70 -r1.71 src/bin/sh/parser.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
From: Christos Zoulas <christos@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/11317 CVS commit: src/bin/sh
Date: Fri, 7 Nov 2008 15:18:11 +0000 (UTC)
Module Name: src
Committed By: christos
Date: Fri Nov 7 15:18:11 UTC 2008
Modified Files:
src/bin/sh: parser.c
Log Message:
Try a different fix for PR/11317: Don't ignore errors in list().
To generate a diff of this commit:
cvs rdiff -r1.71 -r1.72 src/bin/sh/parser.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->closed
State-Changed-By: christos@NetBSD.org
State-Changed-When: Fri, 07 Nov 2008 10:42:42 -0500
State-Changed-Why:
fixed, differently
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.