[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [14509] trunk/blender/source/blender/ blenkernel/intern/modifier.c: Cloth: Fix point cache memory leak when duplicating cloth
Daniel Genrich
daniel.genrich at gmx.net
Tue Apr 22 00:02:16 CEST 2008
Revision: 14509
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=14509
Author: genscher
Date: 2008-04-22 00:02:15 +0200 (Tue, 22 Apr 2008)
Log Message:
-----------
Cloth: Fix point cache memory leak when duplicating cloth
Modified Paths:
--------------
trunk/blender/source/blender/blenkernel/intern/modifier.c
Modified: trunk/blender/source/blender/blenkernel/intern/modifier.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/modifier.c 2008-04-21 21:30:50 UTC (rev 14508)
+++ trunk/blender/source/blender/blenkernel/intern/modifier.c 2008-04-21 22:02:15 UTC (rev 14509)
@@ -5142,11 +5142,14 @@
if(tclmd->sim_parms)
MEM_freeN(tclmd->sim_parms);
if(tclmd->coll_parms)
- MEM_freeN(tclmd->coll_parms);
+ MEM_freeN(tclmd->coll_parms);
+ if(tclmd->point_cache)
+ BKE_ptcache_free(tclmd->point_cache);
tclmd->sim_parms = MEM_dupallocN(clmd->sim_parms);
tclmd->coll_parms = MEM_dupallocN(clmd->coll_parms);
tclmd->point_cache = BKE_ptcache_copy(clmd->point_cache);
+ tclmd->clothObject = NULL;
}
static int clothModifier_dependsOnTime(ModifierData *md)
More information about the Bf-blender-cvs
mailing list