summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2015-03-02 14:50:17 +0000
committerIngo Schwarze <schwarze@openbsd.org>2015-03-02 14:50:17 +0000
commitbf7c1869669b3860fa6597e6b4318ba2c63ae26e (patch)
tree2a36d0eb5c79e53fb21405081a9c01aa52d937a2
parent9db529ea6c2a10761e905b75074060e913316170 (diff)
downloadmandoc-bf7c1869669b3860fa6597e6b4318ba2c63ae26e.tar.gz
If a non-gz manual is read after a gzipped manual, refrain
from throwing a bogus error "wait: No child processes". As reported by Baptiste Daroussin <bapt at FreeBSD dot org>, clearing the state variable curp->child after use was forgotten.
-rw-r--r--read.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/read.c b/read.c
index 75c3b55a..7dabc2e4 100644
--- a/read.c
+++ b/read.c
@@ -868,6 +868,7 @@ mparse_wait(struct mparse *curp)
perror("wait");
exit((int)MANDOCLEVEL_SYSERR);
}
+ curp->child = 0;
if (WIFSIGNALED(status)) {
mandoc_vmsg(MANDOCERR_FILE, curp, 0, 0,
"gunzip died from signal %d", WTERMSIG(status));