patch 9.1.0168: too many STRLEN() calls

Problem:  too many STRLEN() calls
Solution: Make use of ml_get_len() calls instead
          (John Marriott)

closes: #14123

Signed-off-by: John Marriott <basilisk@internode.on.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
John Marriott
2024-03-11 22:04:45 +01:00
committed by Christian Brabandt
parent 5cd86c6cff
commit bfcc895482
6 changed files with 19 additions and 17 deletions

View File

@ -3661,7 +3661,7 @@ ml_replace_len(
curbuf->b_ml.ml_line_ptr = line;
curbuf->b_ml.ml_line_len = len;
curbuf->b_ml.ml_line_textlen = len_arg + 1;
curbuf->b_ml.ml_line_textlen = len_arg + !has_props;
curbuf->b_ml.ml_line_lnum = lnum;
curbuf->b_ml.ml_flags = (curbuf->b_ml.ml_flags | ML_LINE_DIRTY) & ~ML_EMPTY;