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:
authorAntony Riakiotakis <kalast@gmail.com>2013-03-17 20:53:35 +0400
committerAntony Riakiotakis <kalast@gmail.com>2013-03-17 20:53:35 +0400
commit008983004441e6594d87c5ed982a2d4e273d3a57 (patch)
tree88870d3acf01f49870cdbbb1deae044465a95da9
parent0a4b030145fdad2b36290454bbd3ba37406d4f9a (diff)
Fix evil own bug: paint_redraw accessed freed memory. Still doesn't
solve problem not being able to paint with black in image editor.
-rw-r--r--source/blender/editors/sculpt_paint/paint_image.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_image.c b/source/blender/editors/sculpt_paint/paint_image.c
index 6645015a2b2..144dfa948d0 100644
--- a/source/blender/editors/sculpt_paint/paint_image.c
+++ b/source/blender/editors/sculpt_paint/paint_image.c
@@ -529,6 +529,8 @@ static void paint_stroke_done(const bContext *C, struct PaintStroke *stroke)
ToolSettings *settings = scene->toolsettings;
PaintOperation *pop = paint_stroke_mode_data(stroke);
+ paint_redraw(C, pop, 1);
+
if (pop->timer)
WM_event_remove_timer(CTX_wm_manager(C), CTX_wm_window(C), pop->timer);
@@ -541,7 +543,6 @@ static void paint_stroke_done(const bContext *C, struct PaintStroke *stroke)
paint_2d_stroke_done(pop->custom_paint);
}
- paint_redraw(C, pop, 1);
undo_paint_push_end(UNDO_PAINT_IMAGE);
/* duplicate warning, see texpaint_init