mirror of
https://github.com/vim/vim.git
synced 2025-09-06 21:53:38 -04:00
updated for version 7.3.066
Problem: Crash when changing to another window while in a :vimgrep command. (Christian Brabandt) Solution: When wiping out the dummy before, remove it from aucmd_win.
This commit is contained in:
parent
4dbbff57ba
commit
0785ccf995
@ -3432,6 +3432,7 @@ load_dummy_buffer(fname)
|
|||||||
char_u *fname;
|
char_u *fname;
|
||||||
{
|
{
|
||||||
buf_T *newbuf;
|
buf_T *newbuf;
|
||||||
|
buf_T *newbuf_to_wipe = NULL;
|
||||||
int failed = TRUE;
|
int failed = TRUE;
|
||||||
aco_save_T aco;
|
aco_save_T aco;
|
||||||
|
|
||||||
@ -3468,15 +3469,19 @@ load_dummy_buffer(fname)
|
|||||||
failed = FALSE;
|
failed = FALSE;
|
||||||
if (curbuf != newbuf)
|
if (curbuf != newbuf)
|
||||||
{
|
{
|
||||||
/* Bloody autocommands changed the buffer! */
|
/* Bloody autocommands changed the buffer! Can happen when
|
||||||
if (buf_valid(newbuf))
|
* using netrw and editing a remote file. Use the current
|
||||||
wipe_buffer(newbuf, FALSE);
|
* buffer instead, delete the dummy one after restoring the
|
||||||
|
* window stuff. */
|
||||||
|
newbuf_to_wipe = newbuf;
|
||||||
newbuf = curbuf;
|
newbuf = curbuf;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* restore curwin/curbuf and a few other things */
|
/* restore curwin/curbuf and a few other things */
|
||||||
aucmd_restbuf(&aco);
|
aucmd_restbuf(&aco);
|
||||||
|
if (newbuf_to_wipe != NULL && buf_valid(newbuf_to_wipe))
|
||||||
|
wipe_buffer(newbuf_to_wipe, FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!buf_valid(newbuf))
|
if (!buf_valid(newbuf))
|
||||||
|
@ -714,6 +714,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
66,
|
||||||
/**/
|
/**/
|
||||||
65,
|
65,
|
||||||
/**/
|
/**/
|
||||||
|
Loading…
x
Reference in New Issue
Block a user