summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2017-02-10 15:57:47 +0000
committerIngo Schwarze <schwarze@openbsd.org>2017-02-10 15:57:47 +0000
commitfb73b20a2450598a122b50db2d3303731550592b (patch)
treed673dcb5d63ce0ed70647769f8a29817d934a536
parentb776d6210ef191ec5f74f091f56ded6b4667f3c4 (diff)
downloadmandoc-fb73b20a2450598a122b50db2d3303731550592b.tar.gz
merge main.c 1.281, manpath.c 1.33: -Ttree -Onoval
-rw-r--r--main.c6
-rw-r--r--manpath.c5
2 files changed, 8 insertions, 3 deletions
diff --git a/main.c b/main.c
index aca179a2..c62ed4d8 100644
--- a/main.c
+++ b/main.c
@@ -763,7 +763,8 @@ parse(struct curparse *curp, int fd, const char *file)
if (man == NULL)
return;
if (man->macroset == MACROSET_MDOC) {
- mdoc_validate(man);
+ if (curp->outtype != OUTT_TREE || !curp->outopts->noval)
+ mdoc_validate(man);
switch (curp->outtype) {
case OUTT_HTML:
html_mdoc(curp->outdata, man);
@@ -786,7 +787,8 @@ parse(struct curparse *curp, int fd, const char *file)
}
}
if (man->macroset == MACROSET_MAN) {
- man_validate(man);
+ if (curp->outtype != OUTT_TREE || !curp->outopts->noval)
+ man_validate(man);
switch (curp->outtype) {
case OUTT_HTML:
html_man(curp->outdata, man);
diff --git a/manpath.c b/manpath.c
index 265ea6f5..dbf29ab7 100644
--- a/manpath.c
+++ b/manpath.c
@@ -277,7 +277,7 @@ manconf_output(struct manoutput *conf, const char *cp, int fromfile)
{
const char *const toks[] = {
"includes", "man", "paper", "style",
- "indent", "width", "fragment", "mdoc"
+ "indent", "width", "fragment", "mdoc", "noval"
};
const char *errstr;
@@ -361,6 +361,9 @@ manconf_output(struct manoutput *conf, const char *cp, int fromfile)
case 7:
conf->mdoc = 1;
return 0;
+ case 8:
+ conf->noval = 1;
+ return 0;
default:
if (fromfile)
warnx("-O %s: Bad argument", cp);