diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-07-23 13:31:03 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-07-23 13:31:03 +0000 |
commit | 806c80ef1d9f307a8386c90d661a9d26f212190c (patch) | |
tree | 2707e2fbfc19012082ad490b617658eaabaaaa84 /eqn.c | |
parent | a7a54c9b7efa4e0e902e2bd8a744520aefefb825 (diff) | |
download | mandoc-806c80ef1d9f307a8386c90d661a9d26f212190c.tar.gz |
Raise a warning when text follows the `EN'.
Diffstat (limited to 'eqn.c')
-rw-r--r-- | eqn.c | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -285,9 +285,15 @@ eqn_read(struct eqn_node **epp, int ln, * validate the full equation. */ - if (0 == strcmp(p, ".EN")) { + if (0 == strncmp(p, ".EN", 3)) { er = eqn_end(ep); *epp = NULL; + p += 3; + while (' ' == *p || '\t' == *p) + p++; + if ('\0' == *p) + return(er); + mandoc_msg(MANDOCERR_ARGSLOST, ep->parse, ln, pos, NULL); return(er); } |