aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlonerover <pathfinder1644@yahoo.com>2016-12-27 00:25:59 +0800
committerJustin M. Keyes <justinkz@gmail.com>2016-12-26 11:25:59 -0500
commit18cb09e09513dc69a69578940873a455a303247b (patch)
treecd8d2662d09c6c30a84eafb8ae1edd217acfd8fd
parentc1d1493eb27f03e647b1e373e416e89195255d73 (diff)
downloadrneovim-18cb09e09513dc69a69578940873a455a303247b.tar.gz
rneovim-18cb09e09513dc69a69578940873a455a303247b.tar.bz2
rneovim-18cb09e09513dc69a69578940873a455a303247b.zip
vim-patch:7.4.1780 (#5828)
Problem: Warnings reported by cppcheck. Solution: Fix the warnings. (Dominique Pelle) https://github.com/vim/vim/commit/dc633cf82758f67f656cda7fa8ccc30414ee53f8
-rw-r--r--src/nvim/misc1.c2
-rw-r--r--src/nvim/ops.c2
-rw-r--r--src/nvim/version.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/nvim/misc1.c b/src/nvim/misc1.c
index 4ab059c923..71aa6e83e5 100644
--- a/src/nvim/misc1.c
+++ b/src/nvim/misc1.c
@@ -566,7 +566,7 @@ open_line (
int i;
int l;
- for (i = 0; p[i] != NUL && i < lead_len; i += l) {
+ for (i = 0; i < lead_len && p[i] != NUL; i += l) {
l = (*mb_ptr2len)(p + i);
if (vim_strnsize(p, i + l) > repl_size)
break;
diff --git a/src/nvim/ops.c b/src/nvim/ops.c
index dfa89acb1a..9e95c1a3e7 100644
--- a/src/nvim/ops.c
+++ b/src/nvim/ops.c
@@ -4607,7 +4607,7 @@ int do_addsub(int op_type, pos_T *pos, int length, linenr_T Prenum1)
goto theend;
}
ptr = buf1;
- if (negative && (!visual || (visual && was_positive))) {
+ if (negative && (!visual || was_positive)) {
*ptr++ = '-';
}
if (pre) {
diff --git a/src/nvim/version.c b/src/nvim/version.c
index ce103ec7dd..c9167bf8fb 100644
--- a/src/nvim/version.c
+++ b/src/nvim/version.c
@@ -660,7 +660,7 @@ static int included_patches[] = {
// 1783,
1782,
// 1781,
- // 1780,
+ 1780,
1779,
// 1778 NA
// 1777 NA