aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/keymap.c
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2022-04-27 20:28:58 +0800
committerzeertzjq <zeertzjq@outlook.com>2022-04-29 15:51:04 +0800
commitbf065d9bb654263e59949a68d0b90fd196ab1ab8 (patch)
treea9f7db21bf6145ca6ac0d6a567a8ec263a5d58f2 /src/nvim/keymap.c
parentf2b512ad75cace9126eb0ea644daedd758c238e6 (diff)
downloadrneovim-bf065d9bb654263e59949a68d0b90fd196ab1ab8.tar.gz
rneovim-bf065d9bb654263e59949a68d0b90fd196ab1ab8.tar.bz2
rneovim-bf065d9bb654263e59949a68d0b90fd196ab1ab8.zip
vim-patch:8.2.4829: a key may be simplified to NUL
Problem: A key may be simplified to NUL. Solution: Use K_ZERO instead. Use macros instead of hard coded values. (closes vim/vim#10290) https://github.com/vim/vim/commit/17c95d9608370559441bb73941ba6d9a4b6b26bd
Diffstat (limited to 'src/nvim/keymap.c')
-rw-r--r--src/nvim/keymap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/keymap.c b/src/nvim/keymap.c
index 5c4fe13e39..db51237771 100644
--- a/src/nvim/keymap.c
+++ b/src/nvim/keymap.c
@@ -785,7 +785,7 @@ static int extract_modifiers(int key, int *modp, const bool simplify, bool *cons
&& ((key >= '?' && key <= '_') || ASCII_ISALPHA(key))) {
key = CTRL_CHR(key);
modifiers &= ~MOD_MASK_CTRL;
- if (key == 0) { // <C-@> is <Nul>
+ if (key == NUL) { // <C-@> is <Nul>
key = K_ZERO;
}
if (did_simplify != NULL) {