Date: Wed, 28 Dec 2011 22:10:12 +0000 (UTC) From: Jilles Tjoelker <jilles@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r228937 - head/bin/sh Message-ID: <201112282210.pBSMACIg026981@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jilles Date: Wed Dec 28 22:10:12 2011 New Revision: 228937 URL: http://svn.freebsd.org/changeset/base/228937 Log: sh: Do not force special builtins non-special in optimized command subst. This is not necessary: errors are already caught in evalbackcmd() and forcelocal handles changes to variables. Note that this depends on r223024. MFC after: 4 weeks Modified: head/bin/sh/eval.c Modified: head/bin/sh/eval.c ============================================================================== --- head/bin/sh/eval.c Wed Dec 28 20:27:18 2011 (r228936) +++ head/bin/sh/eval.c Wed Dec 28 22:10:12 2011 (r228937) @@ -978,7 +978,6 @@ evalcommand(union node *cmd, int flags, memout.nextc = memout.buf; memout.bufsize = 64; mode |= REDIR_BACKQ; - cmdentry.special = 0; } savecmdname = commandname; savetopfile = getcurrentfile(); @@ -999,7 +998,7 @@ evalcommand(union node *cmd, int flags, * If there is no command word, redirection errors should * not be fatal but assignment errors should. */ - if (argc == 0 && !(flags & EV_BACKCMD)) + if (argc == 0) cmdentry.special = 1; listsetvar(cmdenviron, cmdentry.special ? 0 : VNOSET); if (argc > 0)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201112282210.pBSMACIg026981>