# HG changeset patch # User Bram Moolenaar # Date 1544740206 -3600 # Node ID 7713ceb8c5931803a7f5a1bac9598db871738482 # Parent 0ea0a6a7d0993df05790d985a029761e5c84fde0 patch 8.1.0581: double free without the text properties feature commit https://github.com/vim/vim/commit/ca79a5fc3b383dcfc8ed2077688ea69dafadc6e7 Author: Bram Moolenaar Date: Thu Dec 13 23:16:36 2018 +0100 patch 8.1.0581: double free without the text properties feature Problem: Double free without the text properties feature. Solution: Reset the dirty flag. diff --git a/src/memline.c b/src/memline.c --- a/src/memline.c +++ b/src/memline.c @@ -3176,9 +3176,9 @@ ml_replace_len(linenr_T lnum, char_u *li { // another line is buffered, flush it ml_flush_line(curbuf); + curbuf->b_ml.ml_flags &= ~ML_LINE_DIRTY; #ifdef FEAT_TEXT_PROP - curbuf->b_ml.ml_flags &= ~ML_LINE_DIRTY; if (has_any_text_properties(curbuf)) // Need to fetch the old line to copy over any text properties. ml_get_buf(curbuf, lnum, TRUE); diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -800,6 +800,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 581, +/**/ 580, /**/ 579,