From a05690ae2d1caa7b94d3ab4367515714722d4730 Mon Sep 17 00:00:00 2001 From: svaante Date: Thu, 16 Feb 2017 11:59:01 +0100 Subject: tui.c: Handle missing "key_dc" terminfo entry (#6128) Closes #6025 --- src/nvim/tui/tui.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nvim/tui/tui.c b/src/nvim/tui/tui.c index ed82e23be2..9fbbe8be92 100644 --- a/src/nvim/tui/tui.c +++ b/src/nvim/tui/tui.c @@ -1014,7 +1014,7 @@ static const char *tui_tk_ti_getstr(const char *name, const char *value, } else if (strcmp(name, "key_dc") == 0) { ILOG("libtermkey:kdch1=%s", value); // Vim: "If and are now the same, redefine ." - if (stty_erase != NULL && strcmp(stty_erase, value) == 0) { + if (stty_erase != NULL && value != NULL && strcmp(stty_erase, value) == 0) { return stty_erase[0] == DEL ? (char *)CTRL_H_STR : (char *)DEL_STR; } } -- cgit