[Bf-blender-cvs] [1d3aedfb2e5] greasepencil-object: GP: Fix segment fault using cutter
Antonioya
noreply at git.blender.org
Thu Jan 3 10:52:21 CET 2019
Commit: 1d3aedfb2e539cb2b10a8e4a8f83e5598833f51e
Author: Antonioya
Date: Thu Jan 3 10:50:50 2019 +0100
Branches: greasepencil-object
https://developer.blender.org/rB1d3aedfb2e539cb2b10a8e4a8f83e5598833f51e
GP: Fix segment fault using cutter
The layer can be empty without frames.
===================================================================
M source/blender/editors/gpencil/gpencil_edit.c
===================================================================
diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c
index 393f15608eb..0051e66cc7f 100644
--- a/source/blender/editors/gpencil/gpencil_edit.c
+++ b/source/blender/editors/gpencil/gpencil_edit.c
@@ -3832,6 +3832,9 @@ static int gpencil_cutter_lasso_select(
bGPDstroke *gpsn;
for (bGPDlayer *gpl = gpd->layers.first; gpl; gpl = gpl->next) {
bGPDframe *gpf = gpl->actframe;
+ if (gpf == NULL) {
+ continue;
+ }
for (bGPDstroke *gps = gpf->strokes.first; gps; gps = gpsn) {
gpsn = gps->next;
if (gps->flag & GP_STROKE_SELECT) {
More information about the Bf-blender-cvs
mailing list