aboutsummaryrefslogtreecommitdiffhomepage
path: root/io.c
diff options
context:
space:
mode:
Diffstat (limited to 'io.c')
-rw-r--r--io.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/io.c b/io.c
index b3119fc..58ebf17 100644
--- a/io.c
+++ b/io.c
@@ -1011,10 +1011,11 @@ vdiag(const struct span *span, enum diagkind kind, const char *fmt, va_list ap)
do {
ioputc(&bstderr, mark);
mark = '~';
- } while (--nmark && ++j < end);
+ } while (--nmark > 0 && ++j < end);
col = 1;
++line;
efmt("%g.\n");
+ --nmark;
}
ioputc(&bstderr, '\n');
}