diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2017-01-08 00:11:23 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2017-01-08 00:11:23 +0000 |
commit | c81e4b80275400dcb0530e3f1c5cae2fc53e4aab (patch) | |
tree | 829505ea8a53690849b134bf6a04a9d477ac8796 /read.c | |
parent | 75d8bee1b6d2966fca4b9729823bc194f3fb390e (diff) | |
download | mandoc-c81e4b80275400dcb0530e3f1c5cae2fc53e4aab.tar.gz |
Stricter validation of the NAME section, in particular:
- require a comma between names
- reject all other text nodes
- reject all empty Nm below NAME, not only in the leading position
- reject Nm after Nd
Diffstat (limited to 'read.c')
-rw-r--r-- | read.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1,7 +1,7 @@ /* $Id$ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> - * Copyright (c) 2010-2016 Ingo Schwarze <schwarze@openbsd.org> + * Copyright (c) 2010-2017 Ingo Schwarze <schwarze@openbsd.org> * Copyright (c) 2010, 2012 Joerg Sonnenberger <joerg@netbsd.org> * * Permission to use, copy, modify, and distribute this software for any @@ -108,10 +108,11 @@ static const char * const mandocerrs[MANDOCERR_MAX] = { "no document body", "content before first section header", "first section is not \"NAME\"", - "NAME section without name", + "NAME section without Nm before Nd", "NAME section without description", "description not at the end of NAME", "bad NAME section content", + "missing comma before name", "missing description line, using \"\"", "sections out of conventional order", "duplicate section title", |