aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/eval.c')
-rw-r--r--src/nvim/eval.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c
index 109504037d..0d7e2f7b5d 100644
--- a/src/nvim/eval.c
+++ b/src/nvim/eval.c
@@ -19626,7 +19626,10 @@ void ex_function(exarg_T *eap)
break;
}
}
- ++p; /* skip the ')' */
+ if (*p != ')') {
+ goto erret;
+ }
+ ++p; // skip the ')'
/* find extra arguments "range", "dict" and "abort" */
for (;; ) {