aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2017-03-21 17:38:30 +0100
committerJustin M. Keyes <justinkz@gmail.com>2017-03-22 18:43:00 +0100
commita24c6cc6a8e180d201c5887935d6dfdc95ac1abf (patch)
treec3ea6401a4b979507028c7ec7aae037e52471f04 /src
parent7e23ce6b4fa843c12e44464a20154d92e95355c6 (diff)
downloadrneovim-a24c6cc6a8e180d201c5887935d6dfdc95ac1abf.tar.gz
rneovim-a24c6cc6a8e180d201c5887935d6dfdc95ac1abf.tar.bz2
rneovim-a24c6cc6a8e180d201c5887935d6dfdc95ac1abf.zip
get_tabpage_arg: satisfy clang warning
vim-patch:8.0.0266
Diffstat (limited to 'src')
-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 2bd5158b33..a06c6a89c8 100644
--- a/src/nvim/ex_docmd.c
+++ b/src/nvim/ex_docmd.c
@@ -4319,7 +4319,7 @@ static int getargopt(exarg_T *eap)
/// When an error is encountered then eap->errmsg is set.
static int get_tabpage_arg(exarg_T *eap)
{
- int tab_number;
+ int tab_number = 0;
int unaccept_arg0 = (eap->cmdidx == CMD_tabmove) ? 0 : 1;
if (eap->arg && *eap->arg != NUL) {
@@ -4368,6 +4368,7 @@ static int get_tabpage_arg(exarg_T *eap)
} else if (eap->addr_count > 0) {
if (unaccept_arg0 && eap->line2 == 0) {
eap->errmsg = e_invrange;
+ tab_number = 0;
} else {
tab_number = eap->line2;
if (!unaccept_arg0 && **eap->cmdlinep == '-') {