fix for memory leak in the knife tool
authorCampbell Barton <ideasman42@gmail.com>
Thu, 26 Apr 2012 04:41:27 +0000 (04:41 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 26 Apr 2012 04:41:27 +0000 (04:41 +0000)
source/blender/editors/mesh/editmesh_knife.c

index 0ace06b1a1a95f8e61abb9157fe0eb6b966d6a42..670b06887eb8398af6a5e185353a7f334176cd97 100644 (file)
@@ -2746,6 +2746,9 @@ static void knifetool_exit(bContext *C, wmOperator *op)
        if (kcd->cagecos)
                MEM_freeN(kcd->cagecos);
 
+       if (kcd->linehits)
+               MEM_freeN(kcd->linehits);
+
        /* destroy kcd itself */
        MEM_freeN(kcd);
        op->customdata = NULL;