summaryrefslogtreecommitdiffstats
path: root/mdoc_validate.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2009-07-17 12:40:48 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2009-07-17 12:40:48 +0000
commit5b36c2d81f09cf709b03ffaf2174f9d15cded999 (patch)
tree5efcfa43514e983f64a70259f94735aeb1cb47c8 /mdoc_validate.c
parentbf9af2d1aeed5f52cb468d8e1b89e8234e0d20c1 (diff)
downloadmandoc-5b36c2d81f09cf709b03ffaf2174f9d15cded999.tar.gz
`sp' documented: validates & produces correct output.
Diffstat (limited to 'mdoc_validate.c')
-rw-r--r--mdoc_validate.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/mdoc_validate.c b/mdoc_validate.c
index d3cca68f..193ba09d 100644
--- a/mdoc_validate.c
+++ b/mdoc_validate.c
@@ -1138,6 +1138,8 @@ post_sp(POST_ARGS)
if (NULL == mdoc->last->child)
return(1);
+ else if ( ! eerr_eq1(mdoc))
+ return(0);
assert(MDOC_TEXT == mdoc->last->child->type);
buf = mdoc->last->child->string;
@@ -1150,7 +1152,7 @@ post_sp(POST_ARGS)
return(mdoc_nerr(mdoc, mdoc->last->child, ENUMFMT));
if ((errno == ERANGE && (lval == LONG_MAX || lval == LONG_MIN)) ||
- (lval > INT_MAX || lval < INT_MIN))
+ (lval > INT_MAX || lval < 0))
return(mdoc_nerr(mdoc, mdoc->last->child, ENUMFMT));
return(1);