aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lines.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/lines.c b/lines.c
index d43c7fe..4ac624a 100644
--- a/lines.c
+++ b/lines.c
@@ -50,6 +50,8 @@ draw_vertical_line(RASTER *restrict raster, double x1, double y1, double y2, int
start = (size_t)y1;
end = (size_t)y2;
+ start -= (size_t)(start == raster->height);
+ end -= (size_t)(end == raster->height);
y = start;
if (ydir > 0) {