From ddde74764409ab380daf4b5b52022b9d40989974 Mon Sep 17 00:00:00 2001 From: KunMing Xie Date: Sat, 23 Jun 2018 18:45:10 +0800 Subject: [PATCH] vim-patch:8.0.0544: cppcheck warnings (#8627) Problem: Cppcheck warnings. Solution: Use temp variable. Change NUL to NULL. Swap conditions. (Dominique Pelle) https://github.com/vim/vim/commit/866c68861071f8cd1ef5a82445bebaafc8626e7e --- src/nvim/farsi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nvim/farsi.c b/src/nvim/farsi.c index fae2c805f9..6de84fbf4d 100644 --- a/src/nvim/farsi.c +++ b/src/nvim/farsi.c @@ -1580,7 +1580,7 @@ static void conv_to_pvim(void) ptr[i] = toF_leading(ptr[i]); i++; - while (canF_Rjoin(ptr[i]) && i < llen) { + while (i < llen && canF_Rjoin(ptr[i])) { ptr[i] = toF_Rjoin(ptr[i]); if (F_isterm(ptr[i]) || !F_isalpha(ptr[i])) { break;