summaryrefslogtreecommitdiffstats
path: root/man.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2010-04-08 07:53:01 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2010-04-08 07:53:01 +0000
commitdddfffcee06b6b91e4f189f71f8b4863c54cf798 (patch)
treeb87bed9f41da468269c6f01819f793a0486094d7 /man.c
parente9ac197eddfe16859b48d764269c476bfd7de49f (diff)
downloadmandoc-dddfffcee06b6b91e4f189f71f8b4863c54cf798.tar.gz
Sync'd mdoc.c's function names with man.c.
Prompted by Ingo and Claus Assman, added warn/ignore for text lines beginning with `\."'.
Diffstat (limited to 'man.c')
-rw-r--r--man.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/man.c b/man.c
index c74ac21e..878963c1 100644
--- a/man.c
+++ b/man.c
@@ -53,6 +53,7 @@ const char *const __man_merrnames[WERRMAX] = {
"invalid nesting of roff declarations", /* WROFFNEST */
"scope in roff instructions broken", /* WROFFSCOPE */
"document title should be uppercase", /* WTITLECASE */
+ "deprecated comment style", /* WBADCOMMENT */
};
const char *const __man_macronames[MAN_MAX] = {
@@ -378,6 +379,11 @@ man_ptext(struct man *m, int line, char *buf)
int i, j;
char sv;
+ /* Ignore bogus comments. */
+
+ if ('\\' == buf[0] && '.' == buf[1] && '\"' == buf[2])
+ return(man_pwarn(m, line, 0, WBADCOMMENT));
+
/* Literal free-form text whitespace is preserved. */
if (MAN_LITERAL & m->flags) {