diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2017-07-10 22:16:48 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2017-07-10 22:22:59 +0300 |
commit | 8677c76f138e96cf05e2acd2bf3bec480a983223 (patch) | |
tree | 1fed39097885dbc13b51e7d19194e049b8feeace /source/blender/blenkernel | |
parent | 665288ccd7afd37de9c1c21babc701f4b0fca7e3 (diff) |
Fix (unreported) broken uvsculpt in Scene's toolsettings' copying.
This was serious bug actually, probably a crasher in case you free
original or copy after duplication...
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/intern/scene.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c index 4c8b07574af..a15f270a3ee 100644 --- a/source/blender/blenkernel/intern/scene.c +++ b/source/blender/blenkernel/intern/scene.c @@ -288,6 +288,10 @@ Scene *BKE_scene_copy(Main *bmain, Scene *sce, int type) ts->sculpt = MEM_dupallocN(ts->sculpt); BKE_paint_copy(&ts->sculpt->paint, &ts->sculpt->paint); } + if (ts->uvsculpt) { + ts->uvsculpt = MEM_dupallocN(ts->uvsculpt); + BKE_paint_copy(&ts->uvsculpt->paint, &ts->uvsculpt->paint); + } BKE_paint_copy(&ts->imapaint.paint, &ts->imapaint.paint); ts->imapaint.paintcursor = NULL; |