aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2017-03-22 00:22:45 +0100
committerJustin M. Keyes <justinkz@gmail.com>2017-03-22 18:43:00 +0100
commit51bc9f243a0b60205985b42bb47f174379a463c6 (patch)
treee88939fedb3e11dc32dc0287f6dabc6559aa62ab
parent33858ccb9b53d79f3dafbffef8ca7273be7de119 (diff)
downloadrneovim-51bc9f243a0b60205985b42bb47f174379a463c6.tar.gz
rneovim-51bc9f243a0b60205985b42bb47f174379a463c6.tar.bz2
rneovim-51bc9f243a0b60205985b42bb47f174379a463c6.zip
ex_tabnext: Disallow "+NN" arg.
Need to do this explicitly because our implementation of getdigits() is slightly different.
-rw-r--r--src/nvim/ex_docmd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/nvim/ex_docmd.c b/src/nvim/ex_docmd.c
index a06c6a89c8..d815d57a60 100644
--- a/src/nvim/ex_docmd.c
+++ b/src/nvim/ex_docmd.c
@@ -6602,7 +6602,8 @@ static void ex_tabnext(exarg_T *eap)
char_u *p_save = p;
tab_number = getdigits(&p);
- if (p == p_save || *p_save == '-' || *p != NUL || tab_number == 0) {
+ if (p == p_save || *p_save == '-' || *p_save == '+' || *p != NUL
+ || tab_number == 0) {
// No numbers as argument.
eap->errmsg = e_invarg;
return;