buffer: move BUFEMPTY to a function

This commit is contained in:
Thomas Vigouroux
2020-11-24 08:48:05 +01:00
parent 763c852812
commit 7970631fa0
14 changed files with 28 additions and 21 deletions

View File

@@ -2431,7 +2431,7 @@ static void u_undoredo(int undo, bool do_buf_event)
curhead->uh_entry = newlist;
curhead->uh_flags = new_flags;
if ((old_flags & UH_EMPTYBUF) && BUFEMPTY(curbuf)) {
if ((old_flags & UH_EMPTYBUF) && buf_is_empty(curbuf)) {
curbuf->b_ml.ml_flags |= ML_EMPTY;
}
if (old_flags & UH_CHANGED) {