]> granicus.if.org Git - vim/commitdiff
patch 8.2.5069: various warnings from clang on MS-Windows v8.2.5069
authorYegappan Lakshmanan <yegappan@yahoo.com>
Wed, 8 Jun 2022 14:14:09 +0000 (15:14 +0100)
committerBram Moolenaar <Bram@vim.org>
Wed, 8 Jun 2022 14:14:09 +0000 (15:14 +0100)
Problem:    Various warnings from clang on MS-Windows.
Solution:   Fix the code to avoid the warnings. (Yegappan Lakshmanan,
            closes #10538)

src/dosinst.c
src/fileio.c
src/gui_w32.c
src/os_mswin.c
src/os_win32.c
src/version.c

index e77152fddd998db0982046bea7f7c5f3da9198cf..23cf2d31f866716d3642726d3fa0b2c6c8c7e015 100644 (file)
@@ -211,8 +211,8 @@ check_unpack(void)
     {
        printf("ERROR: Cannot find filetype.vim in \"%s\"\n", installdir);
        printf("It looks like you did not unpack the runtime archive.\n");
-       printf("You must unpack the runtime archive \"vim%srt.zip\" before installing.\n",
-               VIM_VERSION_NODOT + 3);
+       printf("You must unpack the runtime archive \"%srt.zip\" before installing.\n",
+               VIM_VERSION_NODOT);
        myexit(1);
     }
 
index e99eb9bb8632a9336238e5a8b29ccc4be18f94e8..2c6c3381c1f860bf8eca42324c7a910ccceffbea 100644 (file)
@@ -1631,7 +1631,6 @@ retry:
                 * Do the conversion.
                 */
                dst = ptr;
-               size = size;
                while (size > 0)
                {
                    found_bad = FALSE;
index 0bac12ac0d8728f80579030201f323510a95bfbe..3e1addbf91cca98d5394a84876c2775306172b41 100644 (file)
@@ -4153,7 +4153,8 @@ _OnMouseWheel(HWND hwnd, WPARAM wParam, LPARAM lParam, int horizontal)
 {
     int                button;
     win_T      *wp;
-    int                modifiers, kbd_modifiers;
+    int                modifiers = 0;
+    int                kbd_modifiers;
     int                zDelta = GET_WHEEL_DELTA_WPARAM(wParam);
     POINT      pt;
 
@@ -4213,7 +4214,7 @@ _OnMouseWheel(HWND hwnd, WPARAM wParam, LPARAM lParam, int horizontal)
     pt.y = GET_Y_LPARAM(lParam);
     ScreenToClient(s_textArea, &pt);
 
-    gui_send_mouse_event(button, pt.x, pt.y, FALSE, kbd_modifiers);
+    gui_send_mouse_event(button, pt.x, pt.y, FALSE, modifiers);
 }
 
 #ifdef USE_SYSMENU_FONT
index 6310a1aaf1a1b0d13b00aa731e8d74dd4a30aece..b6e8d71e438a4497b1d77400495e1cbc68bea40b 100644 (file)
@@ -560,7 +560,7 @@ resolve_appexeclink(char_u *fname)
            && idx < (int)rb->AppExecLinkReparseBuffer.StringCount
            && idx != 2; )
     {
-       if ((*p++ == L'\0'))
+       if (*p++ == L'\0')
            ++idx;
     }
 
index 6a02fe283e4a4a4ed56c359532f410ef32cf1f89..300045b3f9bd74816935cf3c1d5bdfbba1785bfa 100644 (file)
@@ -3495,7 +3495,7 @@ mch_writable(char_u *name)
  * the allocated memory.
  */
     int
-mch_can_exe(char_u *name, char_u **path, int use_path)
+mch_can_exe(char_u *name, char_u **path, int use_path UNUSED)
 {
     return executable_exists((char *)name, path, TRUE, TRUE);
 }
@@ -8379,7 +8379,6 @@ stop_timeout(void)
     const int *
 start_timeout(long msec)
 {
-    UINT interval = (UINT)msec;
     BOOL ret;
 
     timeout_flag = &timeout_flags[flag_idx];
index 1c190159590f6ac9c510228bece46e065399e595..de4f27cdbe96993c6bbbbe46da9701266a0048cd 100644 (file)
@@ -734,6 +734,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    5069,
 /**/
     5068,
 /**/