From 0a148d5e34b0d9ebac29a68a9ec02d6d43d0eb8c Mon Sep 17 00:00:00 2001 From: buliabyak Date: Sat, 29 Aug 2009 03:00:10 +0000 Subject: [PATCH] patch by Alvin for 418798 --- src/live_effects/spiro.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/live_effects/spiro.cpp b/src/live_effects/spiro.cpp index 4aad25f08..abc9c94ca 100644 --- a/src/live_effects/spiro.cpp +++ b/src/live_effects/spiro.cpp @@ -731,8 +731,10 @@ spiro_iter(spiro_seg *s, bandmat *m, int *perm, double *v, int n) add_mat_line(m, v, derivs[1][1], -ends[1][1], 1, j, jk0r, jinc, nmat); add_mat_line(m, v, derivs[2][1], -ends[1][2], 1, j, jk1r, jinc, nmat); add_mat_line(m, v, derivs[3][1], -ends[1][3], 1, j, jk2r, jinc, nmat); - v[jthl] = mod_2pi(v[jthl]); - v[jthr] = mod_2pi(v[jthr]); + if (jthl >= 0) + v[jthl] = mod_2pi(v[jthl]); + if (jthr >= 0) + v[jthr] = mod_2pi(v[jthr]); j += jinc; } if (cyclic) { -- 2.30.2