summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/fold.c8
-rw-r--r--src/version.c2
2 files changed, 9 insertions, 1 deletions
diff --git a/src/fold.c b/src/fold.c
index 405a6ef1..ff1139dc 100644
--- a/src/fold.c
+++ b/src/fold.c
@@ -849,11 +849,17 @@ foldUpdate(wp, top, bot)
fold_T *fp;
/* Mark all folds from top to bot as maybe-small. */
- (void)foldFind(&curwin->w_folds, curwin->w_cursor.lnum, &fp);
+ (void)foldFind(&curwin->w_folds, top, &fp);
while (fp < (fold_T *)curwin->w_folds.ga_data + curwin->w_folds.ga_len
&& fp->fd_top < bot)
{
fp->fd_small = MAYBE;
+
+ /* Not sure if this is the right place to reset fd_flags (suggested by
+ * Lech Lorens). */
+ if (wp->w_foldinvalid)
+ fp->fd_flags = FD_LEVEL;
+
++fp;
}
diff --git a/src/version.c b/src/version.c
index 91ae2ec9..b7aacc13 100644
--- a/src/version.c
+++ b/src/version.c
@@ -682,6 +682,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 356,
+/**/
355,
/**/
354,