summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mdoc.c11
-rw-r--r--mdoc_term.c1
-rw-r--r--mdoc_validate.c2
-rw-r--r--term_ps.c2
4 files changed, 6 insertions, 10 deletions
diff --git a/mdoc.c b/mdoc.c
index 9ec50720..75633266 100644
--- a/mdoc.c
+++ b/mdoc.c
@@ -691,11 +691,11 @@ mdoc_ptext(struct mdoc *m, int line, char *buf, int offs)
return(0);
/*
- * Insert a `Pp' in the case of a blank line. Technically,
+ * Insert a `sp' in the case of a blank line. Technically,
* blank lines aren't allowed, but enough manuals assume this
* behaviour that we want to work around it.
*/
- if ( ! mdoc_elem_alloc(m, line, offs, MDOC_Pp, NULL))
+ if ( ! mdoc_elem_alloc(m, line, offs, MDOC_sp, NULL))
return(0);
m->next = MDOC_NEXT_SIBLING;
@@ -758,14 +758,11 @@ mdoc_pmacro(struct mdoc *m, int ln, char *buf, int offs)
/*
* Copy the first word into a nil-terminated buffer.
- * Stop copying when a tab, space, backslash, or eoln is encountered.
+ * Stop copying when a tab, space, or eoln is encountered.
*/
j = 0;
- while (j < 4 && '\0' != buf[i] &&
- ' ' != buf[i] &&
- '\t' != buf[i] &&
- '\\' != buf[i])
+ while (j < 4 && '\0' != buf[i] && ' ' != buf[i] && '\t' != buf[i])
mac[j++] = buf[i++];
mac[j] = '\0';
diff --git a/mdoc_term.c b/mdoc_term.c
index 9acd6f06..d0edd24d 100644
--- a/mdoc_term.c
+++ b/mdoc_term.c
@@ -81,7 +81,6 @@ static void termp_lb_post(DECL_ARGS);
static void termp_nm_post(DECL_ARGS);
static void termp_pf_post(DECL_ARGS);
static void termp_quote_post(DECL_ARGS);
-static void termp_quote_post(DECL_ARGS);
static void termp_sh_post(DECL_ARGS);
static void termp_ss_post(DECL_ARGS);
diff --git a/mdoc_validate.c b/mdoc_validate.c
index fdadcb7a..8ec87e3e 100644
--- a/mdoc_validate.c
+++ b/mdoc_validate.c
@@ -265,7 +265,7 @@ const struct valids mdoc_valids[MDOC_MAX] = {
{ NULL, NULL }, /* Dx */
{ NULL, posts_text }, /* %Q */
{ NULL, posts_notext }, /* br */
- { NULL, posts_sp }, /* sp */
+ { pres_pp, posts_sp }, /* sp */
{ NULL, posts_text1 }, /* %U */
{ NULL, NULL }, /* Ta */
};
diff --git a/term_ps.c b/term_ps.c
index dde4d95e..68fd15f2 100644
--- a/term_ps.c
+++ b/term_ps.c
@@ -908,7 +908,7 @@ ps_pletter(struct termp *p, int c)
f = (int)p->engine.ps.lastf;
- if (c <= 32 || (c - 32 > MAXCHAR)) {
+ if (c <= 32 || (c - 32 >= MAXCHAR)) {
ps_putchar(p, ' ');
p->engine.ps.pscol += (size_t)fonts[f].gly[0].wx;
return;