diff options
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_edit.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/source/blender/editors/gpencil/gpencil_edit.c b/source/blender/editors/gpencil/gpencil_edit.c index 779ce27ddf1..f9534b74c04 100644 --- a/source/blender/editors/gpencil/gpencil_edit.c +++ b/source/blender/editors/gpencil/gpencil_edit.c @@ -1940,9 +1940,11 @@ static int gp_dissolve_selected_points(bContext *C, eGP_DissolveMode mode) *ndvert = *dvert; ndvert->dw = MEM_dupallocN(dvert->dw); ndvert++; - dvert++; } } + if (gps->dvert != NULL) { + dvert++; + } } break; case GP_DISSOLVE_BETWEEN: @@ -1970,9 +1972,11 @@ static int gp_dissolve_selected_points(bContext *C, eGP_DissolveMode mode) *ndvert = *dvert; ndvert->dw = MEM_dupallocN(dvert->dw); ndvert++; - dvert++; } } + if (gps->dvert != NULL) { + dvert++; + } } /* copy last segment */ (gps->dvert != NULL) ? dvert = gps->dvert + last : NULL; @@ -2001,9 +2005,11 @@ static int gp_dissolve_selected_points(bContext *C, eGP_DissolveMode mode) *ndvert = *dvert; ndvert->dw = MEM_dupallocN(dvert->dw); ndvert++; - dvert++; } } + if (gps->dvert != NULL) { + dvert++; + } } break; } |