summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
Diffstat (limited to 'source')
-rw-r--r--source/fitz/draw-path.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/fitz/draw-path.c b/source/fitz/draw-path.c
index deb17932..52c4af2f 100644
--- a/source/fitz/draw-path.c
+++ b/source/fitz/draw-path.c
@@ -1000,7 +1000,7 @@ fz_dash_moveto(fz_context *ctx, struct sctx *s, float x, float y)
s->offset = 0;
s->phase = s->dash_phase;
- while (s->phase >= s->dash_list[s->offset])
+ while (s->phase > 0 && s->phase >= s->dash_list[s->offset])
{
s->toggle = !s->toggle;
s->phase -= s->dash_list[s->offset];