From owner-cvs-src-old@FreeBSD.ORG Fri May 28 22:59:03 2010 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 64AF51065672 for ; Fri, 28 May 2010 22:59:03 +0000 (UTC) (envelope-from jilles@FreeBSD.org) Received: from repoman.freebsd.org (unknown [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 51C908FC19 for ; Fri, 28 May 2010 22:59:03 +0000 (UTC) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id o4SMx20v023610 for ; Fri, 28 May 2010 22:59:02 GMT (envelope-from jilles@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id o4SMx2EV023609 for cvs-src-old@freebsd.org; Fri, 28 May 2010 22:59:02 GMT (envelope-from jilles@repoman.freebsd.org) Message-Id: <201005282259.o4SMx2EV023609@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to jilles@repoman.freebsd.org using -f From: Jilles Tjoelker Date: Fri, 28 May 2010 22:40:24 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/bin/sh eval.c main.c src/tools/regression/bin/sh/builtins dot2.0 exec2.0 X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 May 2010 22:59:03 -0000 jilles 2010-05-28 22:40:24 UTC FreeBSD src repository Modified files: bin/sh eval.c main.c Added files: tools/regression/bin/sh/builtins dot2.0 exec2.0 Log: SVN rev 208630 on 2010-05-28 22:40:24Z by jilles sh: Recognize "--" in . and exec. Although "--" historically has not been required to be recognized for certain special builtins that do not take options in POSIX, some other implementations recognize options for them, requiring scripts to use "--" or avoid operands starting with "-". Operands starting with "-" can be avoided with eval by prepending a space, and cannot occur with break, continue, exit, return and shift as they only take numbers, nor with times as it does not take operands. With . and exec, avoiding "-" is not so easy as it may require reimplementing the PATH search; therefore the current proposal for POSIX is to require recognition of "--" for them. We continue to accept other strings starting with "-" as operands to . and exec, and also "--" if it is alone to . (which would otherwise be invalid anyway). Revision Changes Path 1.83 +6 -0 src/bin/sh/eval.c 1.39 +8 -2 src/bin/sh/main.c 1.1 +21 -0 src/tools/regression/bin/sh/builtins/dot2.0 (new) 1.1 +25 -0 src/tools/regression/bin/sh/builtins/exec2.0 (new)