aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/highlight.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/highlight.c')
-rw-r--r--src/nvim/highlight.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/nvim/highlight.c b/src/nvim/highlight.c
index c26b00df79..d6a18fcf8e 100644
--- a/src/nvim/highlight.c
+++ b/src/nvim/highlight.c
@@ -174,6 +174,11 @@ int ns_get_hl(NS *ns_hl, int hl_id, bool link, bool nodefault)
{
static int recursive = 0;
+ if (*ns_hl == 0) {
+ // ns=0 (the default namespace) does not have a provider so stop here
+ return -1;
+ }
+
if (*ns_hl < 0) {
if (ns_hl_active <= 0) {
return -1;