GPencil: Verify brush is valid for grease pencil
authorAntonioya <blendergit@gmail.com>
Sun, 5 May 2019 07:10:44 +0000 (09:10 +0200)
committerAntonioya <blendergit@gmail.com>
Sun, 5 May 2019 07:10:44 +0000 (09:10 +0200)
commit47df163b6cd9074d1e41e268911cbab943fb6a80
treeafcd3c25268042cc84a87f0c5c37c7169482a058
parentab9731ccea592bbf8b6931803671b5172a19f7f9
GPencil: Verify brush is valid for grease pencil

Usually the brush type is correct, but for some old files the brush could be a not valid type. In this case, returns the object active material.

This is related to T61413
source/blender/blenkernel/intern/gpencil.c