ash: revert "cat | jobs" fix, it causes more problems than good
This commit is contained in:
parent
f545be083d
commit
41770226bb
@ -4380,6 +4380,7 @@ clear_traps(void)
|
|||||||
|
|
||||||
/* Lives far away from here, needed for forkchild */
|
/* Lives far away from here, needed for forkchild */
|
||||||
static void closescript(void);
|
static void closescript(void);
|
||||||
|
|
||||||
/* Called after fork(), in child */
|
/* Called after fork(), in child */
|
||||||
static void
|
static void
|
||||||
forkchild(struct job *jp, union node *n, int mode)
|
forkchild(struct job *jp, union node *n, int mode)
|
||||||
@ -4424,15 +4425,8 @@ forkchild(struct job *jp, union node *n, int mode)
|
|||||||
setsignal(SIGQUIT);
|
setsignal(SIGQUIT);
|
||||||
setsignal(SIGTERM);
|
setsignal(SIGTERM);
|
||||||
}
|
}
|
||||||
#if JOBS
|
|
||||||
/* For "jobs | cat" to work like in bash, we must retain list of jobs
|
|
||||||
* in child, but we do need to remove ourself */
|
|
||||||
if (jp)
|
|
||||||
freejob(jp);
|
|
||||||
#else
|
|
||||||
for (jp = curjob; jp; jp = jp->prev_job)
|
for (jp = curjob; jp; jp = jp->prev_job)
|
||||||
freejob(jp);
|
freejob(jp);
|
||||||
#endif
|
|
||||||
jobless = 0;
|
jobless = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user