summaryrefslogtreecommitdiffstats
path: root/mandoc.h
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2010-12-10 20:58:56 +0000
committerIngo Schwarze <schwarze@openbsd.org>2010-12-10 20:58:56 +0000
commit5086d878fd97d26b928c5a38d9e1c5dba788cf4a (patch)
tree265018173abe1a7d4bd48a1e847990309a8482be /mandoc.h
parent0ea3458e9a7b752653b5397bb21ee0977a4b77ab (diff)
downloadmandoc-5086d878fd97d26b928c5a38d9e1c5dba788cf4a.tar.gz
Abort endless loops during roff macro and string expansion.
For now, use the simplest conceivable approach, like groff does: Just a fixed, ugly input stack limit. "check it in" kristaps@
Diffstat (limited to 'mandoc.h')
-rw-r--r--mandoc.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/mandoc.h b/mandoc.h
index 041b004f..58c339fd 100644
--- a/mandoc.h
+++ b/mandoc.h
@@ -101,6 +101,7 @@ enum mandocerr {
MANDOCERR_ERROR, /* ===== start of errors ===== */
+ MANDOCERR_ROFFLOOP, /* input stack limit exceeded, infinite loop? */
MANDOCERR_BADCHAR, /* skipping bad character */
MANDOCERR_NOTEXT, /* skipping text before the first section header */
MANDOCERR_MACRO, /* skipping unknown macro */