mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
patch 8.1.2125: fnamemodify() fails when repeating :e
Problem: Fnamemodify() fails when repeating :e. Solution: Do not go before the tail. (Rob Pilling, closes #5024)
This commit is contained in:
@@ -563,7 +563,11 @@ repeat:
|
||||
}
|
||||
else // :r
|
||||
{
|
||||
if (s > tail) // remove one extension
|
||||
char_u *limit = *fnamep;
|
||||
|
||||
if (limit < tail)
|
||||
limit = tail;
|
||||
if (s > limit) // remove one extension
|
||||
*fnamelen = (int)(s - *fnamep);
|
||||
}
|
||||
*usedlen += 2;
|
||||
|
Reference in New Issue
Block a user