diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2010-05-16 00:04:46 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2010-05-16 00:04:46 +0000 |
commit | 95167efd6516f34385b6878dd2f043182e743e05 (patch) | |
tree | a683e28836d17e48751b452fb7168c29d56777f6 | |
parent | 5df307ff5b3b92eb7c1bcbddf7d4ce7a19091bfd (diff) | |
download | mandoc-95167efd6516f34385b6878dd2f043182e743e05.tar.gz |
Fix allowing silly '\'' control character.
-rw-r--r-- | main.c | 2 | ||||
-rw-r--r-- | man.c | 2 | ||||
-rw-r--r-- | mdoc.c | 2 |
3 files changed, 3 insertions, 3 deletions
@@ -574,7 +574,7 @@ pset(const char *buf, int pos, struct curparse *curp, * default to -man, which is more lenient. */ - if (buf[0] == '.') { + if ('.' == buf[0] || '\'' == buf[0]) { for (i = 1; buf[i]; i++) if (' ' != buf[i] && '\t' != buf[i]) break; @@ -151,7 +151,7 @@ int man_parseln(struct man *m, int ln, char *buf) { - return('.' == *buf || '\'' == *buf ? + return(('.' == *buf || '\'' == *buf) ? man_pmacro(m, ln, buf) : man_ptext(m, ln, buf)); } @@ -291,7 +291,7 @@ mdoc_parseln(struct mdoc *m, int ln, char *buf) return(0); m->flags |= MDOC_NEWLINE; - return('.' == *buf ? + return(('.' == *buf || '\'' == *buf) ? mdoc_pmacro(m, ln, buf) : mdoc_ptext(m, ln, buf)); } |