From 062576f679a1bd5cb546bb8081dc97caefe7b51f Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Fri, 11 Dec 2020 19:45:22 -0500 Subject: vim-patch:8.2.0047: cannot skip tests for specific MS-Windows platform (#13461) Problem: Cannot skip tests for specific MS-Windows platform. Solution: Add windowsversion(). https://github.com/vim/vim/commit/0c1e3744ff0cd6c17af773046b876b428ff3dded --- src/nvim/main.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/nvim/main.c') diff --git a/src/nvim/main.c b/src/nvim/main.c index 025312a6e1..fd8264583b 100644 --- a/src/nvim/main.c +++ b/src/nvim/main.c @@ -169,6 +169,14 @@ void early_init(mparm_T *paramp) init_normal_cmds(); // Init the table of Normal mode commands. highlight_init(); +#ifdef WIN32 + OSVERSIONINFO ovi; + ovi.dwOSVersionInfoSize = sizeof(ovi); + GetVersionEx(&ovi); + snprintf(windowsVersion, sizeof(windowsVersion), "%d.%d", + (int)ovi.dwMajorVersion, (int)ovi.dwMinorVersion); +#endif + #if defined(HAVE_LOCALE_H) // Setup to use the current locale (for ctype() and many other things). // NOTE: Translated messages with encodings other than latin1 will not -- cgit