Mercurial > ~dholland > hg > tradcpp > index.cgi
diff directive.c @ 175:ffdb0b73856f
Suppress blank lines later.
Fixes the rest of the bizarre spacing behavior described in changeset
82cc6fa54b01.
Expand t39 to cover more cases, too.
author | David A. Holland |
---|---|
date | Fri, 12 Jun 2015 02:38:04 -0400 |
parents | 6ff17ab68b16 |
children | a2f047301c15 |
line wrap: on
line diff
--- a/directive.c Fri Jun 12 02:21:28 2015 -0400 +++ b/directive.c Fri Jun 12 02:38:04 2015 -0400 @@ -638,7 +638,7 @@ } /* check if we have a directive line (# exactly in column 0) */ - if (line[0] == '#') { + if (len > 0 && line[0] == '#') { skip = 1 + strspn(line + 1, ws); assert(skip <= len); lp->current.column += skip;