Use 0 for the index if the closest point is on the segment which closes the loop...
[synfig.git] / synfig-core / trunk / src / synfig / valuenode_bline.cpp
index 49e9cb5..a5dc1de 100644 (file)
@@ -257,7 +257,7 @@ synfig::find_closest_point(const ValueBase &bline, const Point &pos, Real &radiu
                {
                        closest = d;
                        best_time = time;
-                       best_index = i;
+                       best_index = 0;
                        best_point = curve(best_time);
                }
        }