From 46bcd48abf19f23a2126ed30e912a95d63786648 Mon Sep 17 00:00:00 2001 From: Janne Karhu Date: Fri, 24 Sep 2010 10:49:29 +0000 Subject: [PATCH] Changing loopcut count caused memory errors in some cases due to missing null check. --- source/blender/editors/mesh/loopcut.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/blender/editors/mesh/loopcut.c b/source/blender/editors/mesh/loopcut.c index 174207a71c5..13538a6f218 100644 --- a/source/blender/editors/mesh/loopcut.c +++ b/source/blender/editors/mesh/loopcut.c @@ -252,7 +252,7 @@ static void ringsel_find_edge(tringselOpData *lcd, const bContext *C, ARegion *a { if (lcd->eed) { edgering_sel(lcd, cuts, 0); - } else { + } else if(lcd->edges) { MEM_freeN(lcd->edges); lcd->edges = NULL; lcd->totedge = 0;