Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/blenkernel/intern/scene.c')
-rw-r--r--source/blender/blenkernel/intern/scene.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c
index dc1a55ed0eb..8488d7ab247 100644
--- a/source/blender/blenkernel/intern/scene.c
+++ b/source/blender/blenkernel/intern/scene.c
@@ -177,7 +177,7 @@ Scene *copy_scene(Main *bmain, Scene *sce, int type)
copy_paint(&ts->sculpt->paint, &ts->sculpt->paint);
}
- id_us_plus((ID *)ts->imapaint.brush);
+ copy_paint(&ts->imapaint.paint, &ts->imapaint.paint);
ts->imapaint.paintcursor= NULL;
ts->particle.paintcursor= NULL;
@@ -284,7 +284,8 @@ void free_scene(Scene *sce)
free_paint(&sce->toolsettings->sculpt->paint);
MEM_freeN(sce->toolsettings->sculpt);
}
-
+ free_paint(&sce->toolsettings->imapaint.paint);
+
MEM_freeN(sce->toolsettings);
sce->toolsettings = NULL;
}