# HG changeset patch # User Bram Moolenaar # Date 1598902204 -7200 # Node ID 24cef4317d92b96200e90c206f35a2b71b35a716 # Parent 3ea6b4a5369a25112797172000947418ce0065e8 patch 8.2.1554: crash in normal test Commit: https://github.com/vim/vim/commit/07e87e9eb5e7195d47d47c0ca752b6c8372a99ea Author: Bram Moolenaar Date: Mon Aug 31 21:22:40 2020 +0200 patch 8.2.1554: crash in normal test Problem: Crash in normal test. Solution: Skip adjusting marks if there are no folds. diff --git a/src/fold.c b/src/fold.c --- a/src/fold.c +++ b/src/fold.c @@ -1515,6 +1515,9 @@ foldMarkAdjustRecurse( linenr_T last; linenr_T top; + if (gap->ga_len == 0) + return; + // In Insert mode an inserted line at the top of a fold is considered part // of the fold, otherwise it isn't. if ((State & INSERT) && amount == (linenr_T)1 && line2 == MAXLNUM) diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -755,6 +755,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 1554, +/**/ 1553, /**/ 1552,