Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2011-06-20 21:50:59 +0400
committerCampbell Barton <ideasman42@gmail.com>2011-06-20 21:50:59 +0400
commitc849a938a0585b473ecc3d28407f918ddd25df08 (patch)
treee9d918b5452016197cdbcf511d3d2890cf01df2e /source/blender/editors/space_view3d/drawanimviz.c
parent203e02f9d78dc88df42221b88d86a440ce6b70b4 (diff)
fix for crash drawing zero length motion path and a leak with zero length paths.
Diffstat (limited to 'source/blender/editors/space_view3d/drawanimviz.c')
-rw-r--r--source/blender/editors/space_view3d/drawanimviz.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/editors/space_view3d/drawanimviz.c b/source/blender/editors/space_view3d/drawanimviz.c
index ee78fd92b79..aa3ba1a3062 100644
--- a/source/blender/editors/space_view3d/drawanimviz.c
+++ b/source/blender/editors/space_view3d/drawanimviz.c
@@ -117,7 +117,11 @@ void draw_motion_path_instance(Scene *scene,
len = mpath->length;
mpv_start= mpath->points;
}
-
+
+ if(len <= 0) {
+ return;
+ }
+
/* draw curve-line of path */
glShadeModel(GL_SMOOTH);