vim-patch:8.1.0677: look-behind match may use the wrong line number

crash reported in #9584

Problem:    Look-behind match may use the wrong line number. (Dominique Pelle)
Solution:   Use the line number in regsave instead of the one in behind_pos,
            we may be looking at the previous line. (closes vim/vim#3749)
866f355814
This commit is contained in:
Jan Edmund Lazo 2019-02-07 22:43:38 +01:00 committed by Justin M. Keyes
parent 1204421888
commit f1843c0035
1 changed files with 1 additions and 1 deletions

View File

@ -4920,7 +4920,7 @@ regmatch (
}
} else {
const char_u *const line =
reg_getline(behind_pos.rs_u.pos.lnum);
reg_getline(rp->rs_un.regsave.rs_u.pos.lnum);
rp->rs_un.regsave.rs_u.pos.col -=
utf_head_off(line,