Fix crash opening file saved in editmode with a brush image texture

started with recent UV Sculpt tool-system integration rB928becec60d1

Fixes T64094

Reviewers: brecht

Maniphest Tasks: T64094

Differential Revision: https://developer.blender.org/D4788
This commit is contained in:
Philipp Oeser 2019-05-03 09:55:38 +02:00
parent f437b958c3
commit 1006767678
Notes: blender-bot 2023-02-14 06:00:50 +01:00
Referenced by issue #64094, Freeze & sudden crash when opening file.
1 changed files with 4 additions and 1 deletions

View File

@ -82,8 +82,11 @@ static eOverlayControlFlags overlay_flags = 0;
void BKE_paint_invalidate_overlay_tex(Scene *scene, ViewLayer *view_layer, const Tex *tex)
{
Paint *p = BKE_paint_get_active(scene, view_layer);
Brush *br = p->brush;
if (!p) {
return;
}
Brush *br = p->brush;
if (!br) {
return;
}