mirror of
https://github.com/neovim/neovim.git
synced 2025-10-13 05:16:09 +00:00
vim-patch:8.2.4440: crash with specific regexp pattern and string
Problem: Crash with specific regexp pattern and string.
Solution: Stop at the start of the string.
6456fae9ba
This commit is contained in:
@@ -4083,6 +4083,10 @@ static bool regmatch(
|
||||
break;
|
||||
if (rex.input == rex.line) {
|
||||
// backup to last char of previous line
|
||||
if (rex.lnum == 0) {
|
||||
status = RA_NOMATCH;
|
||||
break;
|
||||
}
|
||||
rex.lnum--;
|
||||
rex.line = reg_getline(rex.lnum);
|
||||
// Just in case regrepeat() didn't count right.
|
||||
|
Reference in New Issue
Block a user