Fix might-as-well-be-inifinite loop in VisualToolVectorClip

Originally committed to SVN as r4431.
This commit is contained in:
Thomas Goyne 2010-06-04 03:08:10 +00:00
parent 38d922c57a
commit eff4dcf404

View file

@ -192,7 +192,7 @@ void VisualToolVectorClip::Draw() {
// Draw preview of inserted line
if (mode == 1 || mode == 2) {
if (spline.curves.size()) {
if (spline.curves.size() && video.x > INT_MIN && video.y > INT_MIN) {
SplineCurve *c0 = &spline.curves.front();
SplineCurve *c1 = &spline.curves.back();
DrawDashedLine(video.x,video.y,c0->p1.x,c0->p1.y,6);