1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-03 09:00:21 +00:00

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
This commit is contained in:
Jilles Tjoelker 2011-12-28 22:10:12 +00:00
parent b5f359b7c3
commit a82f5687bf
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=228937

View File

@ -978,7 +978,6 @@ evalcommand(union node *cmd, int flags, struct backcmd *backcmd)
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, struct backcmd *backcmd)
* 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)