Lines Matching refs:urd
276 int run, loop, *urd, pout, pipe;
288 int *urd, envlen, pid, exit, not, job, dash;
802 static void unredirect(int *urd) in unredirect() argument
804 int *rr = urd+1, i; in unredirect()
806 if (!urd) return; in unredirect()
808 for (i = 0; i<*urd; i++, rr += 2) if (rr[0] != -1) { in unredirect()
813 free(urd); in unredirect()
834 unredirect(blk->urd); in pop_block()
2055 static struct sh_process *expand_redir(struct sh_arg *arg, int skip, int *urd) in expand_redir() argument
2063 pp->urd = urd; in expand_redir()
2090 save_redirect(&pp->urd, -2, new); in expand_redir()
2142 if (save_redirect(&pp->urd, -1, to)) break; in expand_redir()
2245 if (save_redirect(&pp->urd, from, to)) bad++; in expand_redir()
2248 --*pp->urd; in expand_redir()
2252 if ((saveclose&1) && save_redirect(&pp->urd, -1, from)) bad++; in expand_redir()
2253 if ((saveclose&4) && save_redirect(&pp->urd, from, 2)) bad++; in expand_redir()
2430 unredirect(pp->urd); in run_command()
2431 pp->urd = 0; in run_command()
3196 unredirect(TT.ff->blk->urd); in run_lines()
3197 TT.ff->blk->urd = 0; in run_lines()
3203 if (save_redirect(&TT.ff->blk->urd, TT.ff->blk->pout, 0)) break; in run_lines()
3218 if (save_redirect(&TT.ff->blk->urd, pipes[1], 1)) { in run_lines()
3226 if (ctl[1] == '&') save_redirect(&TT.ff->blk->urd, 1, 2); in run_lines()
3261 pp = expand_redir(TT.ff->pl->end->arg, 1, TT.ff->blk->urd); in run_lines()
3262 TT.ff->blk->urd = pp->urd; in run_lines()
3263 pp->urd = 0; in run_lines()
3285 TT.ff->blk->urd = 0; in run_lines()
4001 free(TT.pp->urd); in exec_main()
4002 TT.pp->urd = 0; in exec_main()