summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--roff.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/roff.c b/roff.c
index e5f5a2a2..4789f7c8 100644
--- a/roff.c
+++ b/roff.c
@@ -739,10 +739,10 @@ roff_block(ROFF_ARGS)
mandoc_msg(MANDOCERR_REQUEST, r->parse, ln, ppos,
roffs[tok].name);
- while ((*bufp)[pos] && ' ' != (*bufp)[pos])
+ while ((*bufp)[pos] && ! isspace((unsigned char)(*bufp)[pos]))
pos++;
- while (' ' == (*bufp)[pos])
+ while (isspace((unsigned char)(*bufp)[pos]))
(*bufp)[pos++] = '\0';
}
@@ -763,9 +763,7 @@ roff_block(ROFF_ARGS)
/* If present, process the custom end-of-line marker. */
sv = pos;
- while ((*bufp)[pos] &&
- ' ' != (*bufp)[pos] &&
- '\t' != (*bufp)[pos])
+ while ((*bufp)[pos] && ! isspace((unsigned char)(*bufp)[pos]))
pos++;
/*