diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2010-08-20 23:22:09 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2010-08-20 23:22:09 +0000 |
commit | 46df402950b28191cf436117d4ec8cbf981a4a75 (patch) | |
tree | 77635f470328a72b8e67de763a3d43ea453dd4b8 /term.c | |
parent | ffbd731dc451c848b76e3a18e38fd28e9f34e6b7 (diff) | |
download | mandoc-46df402950b28191cf436117d4ec8cbf981a4a75.tar.gz |
When a column contains trailing spaces, calculate the padding
to the start of the next column correctly.
Fixing a problem found by jmc@ in sysctl(3), reminded by kettenis@.
Diffstat (limited to 'term.c')
-rw-r--r-- | term.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -275,6 +275,12 @@ term_flushln(struct termp *p) vis = vend; } + /* + * If there was trailing white space, it was not printed; + * so reset the cursor position accordingly. + */ + vis -= vbl; + p->col = 0; p->overstep = 0; |