diff options
author | Antony Riakiotakis <kalast@gmail.com> | 2014-04-02 19:25:03 +0400 |
---|---|---|
committer | Antony Riakiotakis <kalast@gmail.com> | 2014-04-02 19:25:03 +0400 |
commit | 6785e45951288bca8176893dba46e73c10ad2673 (patch) | |
tree | 938d7cf7a32b7378433162f539c8015102d145c4 /source/blender | |
parent | 965e5039f5d158c7c89d525e83b830f9ad10adc0 (diff) |
Undoing masks in dyntopo leaked memory
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/editors/sculpt_paint/sculpt_undo.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/editors/sculpt_paint/sculpt_undo.c b/source/blender/editors/sculpt_paint/sculpt_undo.c index 5adef17c6ad..724e3ff1849 100644 --- a/source/blender/editors/sculpt_paint/sculpt_undo.c +++ b/source/blender/editors/sculpt_paint/sculpt_undo.c @@ -296,6 +296,9 @@ static void sculpt_undo_bmesh_restore_generic(bContext *C, for (i = 0; i < totnode; i++) { BKE_pbvh_node_mark_redraw(nodes[i]); } + + if (nodes) + MEM_freeN(nodes); } else { /* A bit lame, but for now just recreate the PBVH. The alternative |