]> granicus.if.org Git - vim/commitdiff
patch 8.1.1650: warning for using uninitialized variable v8.1.1650
authorBram Moolenaar <Bram@vim.org>
Mon, 8 Jul 2019 18:08:44 +0000 (20:08 +0200)
committerBram Moolenaar <Bram@vim.org>
Mon, 8 Jul 2019 18:08:44 +0000 (20:08 +0200)
Problem:    Warning for using uninitialized variable. (Tony Mechelynck)
Solution:   Simplify the code by always using the mouse coordinates.

src/beval.c
src/version.c

index 010e20105197d9b0bbabf3e2cb12923844ddfcba..68df2be9eacb12b11c4d84825692f60d6266425d 100644 (file)
@@ -131,24 +131,16 @@ find_word_under_cursor(
  */
     int
 get_beval_info(
-    BalloonEval        *beval,
-    int                getword,
-    win_T      **winp,
-    linenr_T   *lnump,
-    char_u     **textp,
-    int                *colp)
+       BalloonEval     *beval,
+       int             getword,
+       win_T           **winp,
+       linenr_T        *lnump,
+       char_u          **textp,
+       int             *colp)
 {
-    int                row, col;
+    int                row = mouse_row;
+    int                col = mouse_col;
 
-# ifdef FEAT_BEVAL_TERM
-#  ifdef FEAT_GUI
-    if (!gui.in_use)
-#  endif
-    {
-       row = mouse_row;
-       col = mouse_col;
-    }
-# endif
 # ifdef FEAT_GUI
     if (gui.in_use)
     {
index 82f90932ca749cfd7a495d68f89f0422f610a0d8..6ad48828b7710c6ef8a5418f39594382045688db 100644 (file)
@@ -777,6 +777,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1650,
 /**/
     1649,
 /**/