aboutsummaryrefslogtreecommitdiff
path: root/shell/hush.c
diff options
context:
space:
mode:
Diffstat (limited to 'shell/hush.c')
-rw-r--r--shell/hush.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/shell/hush.c b/shell/hush.c
index 1709fd9d1..10788b8e7 100644
--- a/shell/hush.c
+++ b/shell/hush.c
@@ -6615,7 +6615,7 @@ static int checkjobs_and_fg_shell(struct pipe *fg_pipe)
6615 * cmd ; ... { list } ; ... 6615 * cmd ; ... { list } ; ...
6616 * cmd && ... { list } && ... 6616 * cmd && ... { list } && ...
6617 * cmd || ... { list } || ... 6617 * cmd || ... { list } || ...
6618 * If it is, then we can run cmd as a builtin, NOFORK [do we do this?], 6618 * If it is, then we can run cmd as a builtin, NOFORK,
6619 * or (if SH_STANDALONE) an applet, and we can run the { list } 6619 * or (if SH_STANDALONE) an applet, and we can run the { list }
6620 * with run_list. If it isn't one of these, we fork and exec cmd. 6620 * with run_list. If it isn't one of these, we fork and exec cmd.
6621 * 6621 *
@@ -6797,13 +6797,12 @@ static NOINLINE int run_pipe(struct pipe *pi)
6797 } 6797 }
6798 6798
6799 /* Expand the rest into (possibly) many strings each */ 6799 /* Expand the rest into (possibly) many strings each */
6800 if (0) {}
6801#if ENABLE_HUSH_BASH_COMPAT 6800#if ENABLE_HUSH_BASH_COMPAT
6802 else if (command->cmd_type == CMD_SINGLEWORD_NOGLOB) { 6801 if (command->cmd_type == CMD_SINGLEWORD_NOGLOB) {
6803 argv_expanded = expand_strvec_to_strvec_singleword_noglob(argv + command->assignment_cnt); 6802 argv_expanded = expand_strvec_to_strvec_singleword_noglob(argv + command->assignment_cnt);
6804 } 6803 } else
6805#endif 6804#endif
6806 else { 6805 {
6807 argv_expanded = expand_strvec_to_strvec(argv + command->assignment_cnt); 6806 argv_expanded = expand_strvec_to_strvec(argv + command->assignment_cnt);
6808 } 6807 }
6809 6808
@@ -6865,7 +6864,7 @@ static NOINLINE int run_pipe(struct pipe *pi)
6865 return rcode; 6864 return rcode;
6866 } 6865 }
6867 6866
6868 if (ENABLE_FEATURE_SH_STANDALONE) { 6867 if (ENABLE_FEATURE_SH_NOFORK) {
6869 int n = find_applet_by_name(argv_expanded[0]); 6868 int n = find_applet_by_name(argv_expanded[0]);
6870 if (n >= 0 && APPLET_IS_NOFORK(n)) { 6869 if (n >= 0 && APPLET_IS_NOFORK(n)) {
6871 rcode = redirect_and_varexp_helper(&new_env, &old_vars, command, squirrel, argv_expanded); 6870 rcode = redirect_and_varexp_helper(&new_env, &old_vars, command, squirrel, argv_expanded);