]> granicus.if.org Git - vim/commitdiff
patch 8.1.1207: some compilers give warning messages v8.1.1207
authorBram Moolenaar <Bram@vim.org>
Fri, 26 Apr 2019 18:33:00 +0000 (20:33 +0200)
committerBram Moolenaar <Bram@vim.org>
Fri, 26 Apr 2019 18:33:00 +0000 (20:33 +0200)
Problem:    Some compilers give warning messages.
Solution:   Initialize variables, change printf() argument. (Christian
            Brabandt, closes #4305)

src/eval.c
src/screen.c
src/undo.c
src/version.c
src/window.c

index dd662875132fe0a7b0a41a7c5c69d6e01e828e98..bf82d02633fa5ee2d504ad2e57491f588461b6d5 100644 (file)
@@ -4051,7 +4051,7 @@ eval6(
     varnumber_T        n1, n2;
 #ifdef FEAT_FLOAT
     int                use_float = FALSE;
-    float_T    f1 = 0, f2;
+    float_T    f1 = 0, f2 = 0;
 #endif
     int                error = FALSE;
 
index 67a0db943de216d8449eb3d4c86cc920979a1193..862a63584215ffd97ae4647931e315800f5a0825 100644 (file)
@@ -549,8 +549,8 @@ update_screen(int type_arg)
 #endif
 #ifdef FEAT_GUI
     int                did_undraw = FALSE;
-    int                gui_cursor_col;
-    int                gui_cursor_row;
+    int                gui_cursor_col = 0;
+    int                gui_cursor_row = 0;
 #endif
     int                no_update = FALSE;
 
index 978549aeae938a4aa10db044e10daa99e926a7be..1d26144495f63df8f3066429d7c0d2b631790b1d 100644 (file)
@@ -2271,7 +2271,7 @@ undo_time(
     u_header_T     *uhp = NULL;
     u_header_T     *last;
     int                    mark;
-    int                    nomark;
+    int                    nomark = 0;  // shut up compiler
     int                    round;
     int                    dosec = sec;
     int                    dofile = file;
index 454ea5629d3e9bcb984c779977fcffa3d02ef42c..7cbd2b54a7c26c6a97552b6c35255d4a226bde7e 100644 (file)
@@ -771,6 +771,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1207,
 /**/
     1206,
 /**/
index df82d203fef6baf7a94ad0c5febaee4a9e1f155a..b132361a5a08971be53d577d1351f64abbfa8a91 100644 (file)
@@ -3981,7 +3981,7 @@ enter_tabpage(
     void
 goto_tabpage(int n)
 {
-    tabpage_T  *tp;
+    tabpage_T  *tp = NULL;  // shut up compiler
     tabpage_T  *ttp;
     int                i;