mirror of
https://github.com/neovim/neovim.git
synced 2025-10-17 07:16:09 +00:00
vim-patch:8.0.0370: invalid memory access when setting wildchar empty
Problem: Invalid memory access when setting wildchar empty.
Solution: Avoid going over the end of the option value. (Dominique Pelle,
closes vim/vim#1509) Make option test check all number options with
empty value.
a12e40351d
This commit is contained in:
@@ -1434,7 +1434,7 @@ do_set (
|
||||
|| (long *)varp == &p_wcm)
|
||||
&& (*arg == '<'
|
||||
|| *arg == '^'
|
||||
|| ((!arg[1] || ascii_iswhite(arg[1]))
|
||||
|| (*arg != NUL && (!arg[1] || ascii_iswhite(arg[1]))
|
||||
&& !ascii_isdigit(*arg)))) {
|
||||
value = string_to_key(arg);
|
||||
if (value == 0 && (long *)varp != &p_wcm) {
|
||||
|
Reference in New Issue
Block a user