source@mandoc.bsd.lv
 help / color / mirror / Atom feed
* mdocml: After a leading blank on an output line, the first word was
@ 2013-08-05 23:36 schwarze
  0 siblings, 0 replies; only message in thread
From: schwarze @ 2013-08-05 23:36 UTC (permalink / raw)
  To: source

Log Message:
-----------
After a leading blank on an output line, the first word was counted twice
against vend, causing a premature line break.  Fix that bug by reverting
revision 1.93 which Kristaps committed four years ago.  Kristaps patch is no
longer needed because the code below  /* Write out the [remaining] word. */
now handles leading blanks correctly, probably already for a long time.

This avoids premature line breaks in about a dozen base system manuals,
for example as(1) and gdb(1), and alignment issues in another twenty,
for example mount(2), ip6(4), pfctl(8), and crypto(9).

Modified Files:
--------------
    mdocml:
        term.c

Revision Data
-------------
Index: term.c
===================================================================
RCS file: /usr/vhosts/mdocml.bsd.lv/cvs/mdocml/term.c,v
retrieving revision 1.207
retrieving revision 1.208
diff -Lterm.c -Lterm.c -u -p -r1.207 -r1.208
--- term.c
+++ term.c
@@ -162,7 +162,7 @@ term_flushln(struct termp *p)
 		 */
 
 		for (j = i, jhy = 0; j < p->col; j++) {
-			if ((j && ' ' == p->buf[j]) || '\t' == p->buf[j])
+			if (' ' == p->buf[j] || '\t' == p->buf[j])
 				break;
 
 			/* Back over the the last printed character. */
--
 To unsubscribe send an email to source+unsubscribe@mdocml.bsd.lv

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2013-08-05 23:36 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-05 23:36 mdocml: After a leading blank on an output line, the first word was schwarze

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).