Date: Fri, 28 May 2010 22:40:24 +0000 (UTC) From: Jilles Tjoelker <jilles@FreeBSD.org> To: cvs-src-old@freebsd.org Subject: cvs commit: src/bin/sh eval.c main.c src/tools/regression/bin/sh/builtins dot2.0 exec2.0 Message-ID: <201005282259.o4SMx2EV023609@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
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)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201005282259.o4SMx2EV023609>