mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
vim-patch:7.4.800
Problem: Using freed memory when triggering CmdUndefined autocommands.
Solution: Set pointer to NULL. (Dominique Pelle)
829aef1eb4
This commit is contained in:
parent
ffd143be82
commit
cdc7250cd8
@ -1702,9 +1702,9 @@ static char_u * do_one_cmd(char_u **cmdlinep,
|
|||||||
p = vim_strnsave(ea.cmd, p - ea.cmd);
|
p = vim_strnsave(ea.cmd, p - ea.cmd);
|
||||||
int ret = apply_autocmds(EVENT_CMDUNDEFINED, p, p, TRUE, NULL);
|
int ret = apply_autocmds(EVENT_CMDUNDEFINED, p, p, TRUE, NULL);
|
||||||
xfree(p);
|
xfree(p);
|
||||||
if (ret && !aborting()) {
|
// If the autocommands did something and didn't cause an error, try
|
||||||
p = find_command(&ea, NULL);
|
// finding the command again.
|
||||||
}
|
p = (ret && !aborting()) ? find_command(&ea, NULL) : NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (p == NULL) {
|
if (p == NULL) {
|
||||||
|
@ -488,7 +488,7 @@ static int included_patches[] = {
|
|||||||
803,
|
803,
|
||||||
802,
|
802,
|
||||||
// 801,
|
// 801,
|
||||||
// 800,
|
800,
|
||||||
799,
|
799,
|
||||||
798,
|
798,
|
||||||
// 797,
|
// 797,
|
||||||
|
Loading…
Reference in New Issue
Block a user