optind = 1;
debug_printf("running applet %s\n", name);
run_applet_by_name(name, argc_l, child->argv);
- exit(1);
}
#endif
debug_printf("exec of %s\n",child->argv[0]);
pi->pgrp = 0;
/* Check if we are supposed to run in the foreground */
- if (pi->followup!=PIPE_BG) {
+ if (interactive && pi->followup!=PIPE_BG) {
if ((pi->pgrp = tcgetpgrp(ctty = 2)) < 0
&& (pi->pgrp = tcgetpgrp(ctty = 0)) < 0
&& (pi->pgrp = tcgetpgrp(ctty = 1)) < 0)
old->child->group = ctx->list_head;
*ctx = *old; /* physical copy */
free(old);
- ctx->w=RES_NONE;
}
b_reset (dest);
return 1;