[Bf-blender-cvs] [8ff765a0360] temp-lineart-contained: GPencil: Fix unreported crash in some cases when duplicate a stroke
Antonio Vazquez
noreply at git.blender.org
Sat Dec 19 06:18:55 CET 2020
Commit: 8ff765a03603981fe73ab23ed398718b312c4bea
Author: Antonio Vazquez
Date: Sat Nov 14 15:16:02 2020 +0100
Branches: temp-lineart-contained
https://developer.blender.org/rB8ff765a03603981fe73ab23ed398718b312c4bea
GPencil: Fix unreported crash in some cases when duplicate a stroke
Some pointers were not initialized.
===================================================================
M source/blender/blenkernel/intern/gpencil.c
===================================================================
diff --git a/source/blender/blenkernel/intern/gpencil.c b/source/blender/blenkernel/intern/gpencil.c
index cd4eec1d379..02347a804e3 100644
--- a/source/blender/blenkernel/intern/gpencil.c
+++ b/source/blender/blenkernel/intern/gpencil.c
@@ -933,6 +933,10 @@ bGPDstroke *BKE_gpencil_stroke_duplicate(bGPDstroke *gps_src,
gps_dst->dvert = NULL;
}
}
+ else {
+ gps_dst->points = NULL;
+ gps_dst->dvert = NULL;
+ }
if (dup_curve && gps_src->editcurve != NULL) {
gps_dst->editcurve = BKE_gpencil_stroke_curve_duplicate(gps_src->editcurve);
More information about the Bf-blender-cvs
mailing list