diff options
author | Denys Vlasenko <dvlasenk@redhat.com> | 2020-02-19 11:30:08 +0100 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2020-04-29 16:04:17 +1000 |
commit | 42a0e93a91f88f25f7a7c6a69809e1efe14fb837 (patch) | |
tree | 4c055680698fb9399cb3137f490fb13add5d8b15 | |
parent | builtin: Fix seconds part of times(1) (diff) | |
download | dash-42a0e93a91f88f25f7a7c6a69809e1efe14fb837.tar.gz dash-42a0e93a91f88f25f7a7c6a69809e1efe14fb837.zip |
jobs: Rename DOWAIT_NORMAL to DOWAIT_NONBLOCK
To make it clearer what it is doing: nonblocking wait() Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to '')
-rw-r--r-- | src/jobs.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/jobs.c b/src/jobs.c index f377d8c..ba77c00 100644 --- a/src/jobs.c +++ b/src/jobs.c @@ -78,7 +78,7 @@ #define CUR_STOPPED 0 /* mode flags for dowait */ -#define DOWAIT_NORMAL 0 +#define DOWAIT_NONBLOCK 0 #define DOWAIT_BLOCK 1 #define DOWAIT_WAITCMD 2 @@ -558,7 +558,7 @@ showjobs(struct output *out, int mode) TRACE(("showjobs(%x) called\n", mode)); /* If not even one one job changed, there is nothing to do */ - dowait(DOWAIT_NORMAL, NULL); + dowait(DOWAIT_NONBLOCK, NULL); for (jp = curjob; jp; jp = jp->prev_job) { if (!(mode & SHOW_CHANGED) || jp->changed) @@ -1013,7 +1013,7 @@ waitforjob(struct job *jp) int st; TRACE(("waitforjob(%%%d) called\n", jp ? jobno(jp) : 0)); - dowait(jp ? DOWAIT_BLOCK : DOWAIT_NORMAL, jp); + dowait(jp ? DOWAIT_BLOCK : DOWAIT_NONBLOCK, jp); if (!jp) return exitstatus; @@ -1123,7 +1123,7 @@ out: static int dowait(int block, struct job *jp) { - int pid = block == DOWAIT_NORMAL ? gotsigchld : 1; + int pid = block == DOWAIT_NONBLOCK ? gotsigchld : 1; while (jp ? jp->state == JOBRUNNING : pid > 0) { if (!jp) |