forked from aniani/vim
patch 7.4.2356
Problem: Reading past end of line when using previous substitute pattern. (Dominique Pelle) Solution: Don't set "pat" only set "searchstr".
This commit is contained in:
@@ -1240,14 +1240,13 @@ do_search(
|
||||
{
|
||||
if (spats[RE_SEARCH].pat == NULL) /* no previous pattern */
|
||||
{
|
||||
pat = spats[RE_SUBST].pat;
|
||||
if (pat == NULL)
|
||||
searchstr = spats[RE_SUBST].pat;
|
||||
if (searchstr == NULL)
|
||||
{
|
||||
EMSG(_(e_noprevre));
|
||||
retval = 0;
|
||||
goto end_do_search;
|
||||
}
|
||||
searchstr = pat;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Reference in New Issue
Block a user