updated for version 7.4.261
Problem: When updating the window involves a regexp pattern, an interactive
substitute to replace a "\n" with a line break fails. (Ingo
Karkat)
Solution: Set reg_line_lbr in vim_regsub() and vim_regsub_multi().
diff --git a/src/regexp.c b/src/regexp.c
index 2c364b3..2023714 100644
--- a/src/regexp.c
+++ b/src/regexp.c
@@ -7381,6 +7381,7 @@
reg_mmatch = NULL;
reg_maxline = 0;
reg_buf = curbuf;
+ reg_line_lbr = TRUE;
return vim_regsub_both(source, dest, copy, magic, backslash);
}
#endif
@@ -7400,6 +7401,7 @@
reg_buf = curbuf; /* always works on the current buffer! */
reg_firstlnum = lnum;
reg_maxline = curbuf->b_ml.ml_line_count - lnum;
+ reg_line_lbr = FALSE;
return vim_regsub_both(source, dest, copy, magic, backslash);
}
diff --git a/src/testdir/test79.in b/src/testdir/test79.in
index 56955c2..8278bd8 100644
--- a/src/testdir/test79.in
+++ b/src/testdir/test79.in
Binary files differ
diff --git a/src/testdir/test79.ok b/src/testdir/test79.ok
index 0f6ea45..e22eee0 100644
--- a/src/testdir/test79.ok
+++ b/src/testdir/test79.ok
Binary files differ
diff --git a/src/version.c b/src/version.c
index 1a112d7..8acd83e 100644
--- a/src/version.c
+++ b/src/version.c
@@ -735,6 +735,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 261,
+/**/
260,
/**/
259,