svn commit: r303597 - head/usr.bin/indent
Pedro F. Giffuni
pfg at FreeBSD.org
Sun Jul 31 20:13:02 UTC 2016
Author: pfg
Date: Sun Jul 31 20:13:00 2016
New Revision: 303597
URL: https://svnweb.freebsd.org/changeset/base/303597
Log:
indent(1): Fix wrapping of some lines in comments.
After a blank line was printed (to separate paragraphs in comments), the
next line was sometimes wrapped to the column at which the previous
non-empty line ended. The fix is to reset the last blank pointer (last_bl)
on newline.
References:
https://github.com/pstef/freebsd_indent/commit/345663c07af0758fd10433bde14722dfd900f85c
Differential Revision: https://reviews.freebsd.org/D6966 (Partial)
Submitted by: Piotr Stefaniak
Modified:
head/usr.bin/indent/pr_comment.c
Modified: head/usr.bin/indent/pr_comment.c
==============================================================================
--- head/usr.bin/indent/pr_comment.c Sun Jul 31 20:04:18 2016 (r303596)
+++ head/usr.bin/indent/pr_comment.c Sun Jul 31 20:13:00 2016 (r303597)
@@ -218,6 +218,7 @@ pr_comment(void)
dump_line();
return;
}
+ last_bl = NULL;
if (ps.box_com || ps.last_nl) { /* if this is a boxed comment,
* we dont ignore the newline */
if (s_com == e_com) {
More information about the svn-src-all
mailing list