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:
authorTon Roosendaal <ton@blender.org>2007-02-09 16:02:10 +0300
committerTon Roosendaal <ton@blender.org>2007-02-09 16:02:10 +0300
commit65a4debc724b60c7f32a48bb27791ea2b288c7a2 (patch)
treee94735450165c02a4a0f0c6377836b541887d674 /source/blender/src/editmesh.c
parenta61e2dce428d7fe9691dcd9207b2379d63134283 (diff)
Bugfix #5866
Report showed a Mesh that crashed on entering editmode and use some tools. Appeared to be a mesh index 4 equal to one of the other indices (which makes a corrupted quad). Fix is a sanity check in addfacelist() for enter editmode.
Diffstat (limited to 'source/blender/src/editmesh.c')
-rw-r--r--source/blender/src/editmesh.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/src/editmesh.c b/source/blender/src/editmesh.c
index cb7a063e8b2..f1d6e77fc3f 100644
--- a/source/blender/src/editmesh.c
+++ b/source/blender/src/editmesh.c
@@ -385,6 +385,9 @@ EditFace *addfacelist(EditVert *v1, EditVert *v2, EditVert *v3, EditVert *v4, Ed
EditFace *efa;
EditEdge *e1, *e2=0, *e3=0, *e4=0;
+ /* added sanity check... seems to happen for some tools, or for enter editmode for corrupted meshes */
+ if(v1==v4 || v2==v4 || v3==v4) v4= NULL;
+
/* add face to list and do the edges */
if(exampleEdges) {
e1= addedgelist(v1, v2, exampleEdges->e1);