Commit: patch 9.1.1414: MS-Windows: compile warnings in os_win32.c

2 views
Skip to first unread message

Christian Brabandt

unread,
May 26, 2025, 2:30:16 PM5/26/25
to vim...@googlegroups.com
patch 9.1.1414: MS-Windows: compile warnings in os_win32.c

Commit: https://github.com/vim/vim/commit/2c7ccaab87279b3f1a53b00fe64c3eed9fa89804
Author: John Marriott <basi...@internode.on.net>
Date: Mon May 26 20:25:38 2025 +0200

patch 9.1.1414: MS-Windows: compile warnings in os_win32.c

Problem: MS-Windows: compile warnings in os_win32.c
Solution: update function declarations, correctly access param arg in
set_flag() using (sig_atomic_t) cast (John Marriott)

closes: #17368

Co-authored-by: Hirohito Higashi <h.eas...@gmail.com>
Signed-off-by: John Marriott <basi...@internode.on.net>
Signed-off-by: Christian Brabandt <c...@256bit.org>

diff --git a/src/os_win32.c b/src/os_win32.c
index 740c35a0a..10bbb6c8d 100644
--- a/src/os_win32.c
+++ b/src/os_win32.c
@@ -175,12 +175,12 @@ static int conpty_working = 0;
static int conpty_type = 0;
static int conpty_stable = 0;
static int conpty_fix_type = 0;
-static void vtp_flag_init();
+static void vtp_flag_init(void);

#if !defined(FEAT_GUI_MSWIN) || defined(VIMDLL)
static int vtp_working = 0;
-static void vtp_init();
-static void vtp_exit();
+static void vtp_init(void);
+static void vtp_exit(void);
static void vtp_sgr_bulk(int arg);
static void vtp_sgr_bulks(int argc, int *argv);

@@ -8994,9 +8994,7 @@ static sig_atomic_t *timeout_flag = &timeout_flags[0];
static void CALLBACK
set_flag(void *param, BOOLEAN unused2 UNUSED)
{
- int *timeout_flag = (int *)param;
-
- *timeout_flag = TRUE;
+ *(sig_atomic_t *)param = TRUE;
}

/*
diff --git a/src/version.c b/src/version.c
index adb5654bc..5366f3f2e 100644
--- a/src/version.c
+++ b/src/version.c
@@ -709,6 +709,8 @@ static char *(features[]) =

static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 1414,
/**/
1413,
/**/
Reply all
Reply to author
Forward
0 new messages