diff --git a/windows/utils/version.c b/windows/utils/version.c index a53c2ad3..b626710e 100644 --- a/windows/utils/version.c +++ b/windows/utils/version.c @@ -4,6 +4,11 @@ DWORD osMajorVersion, osMinorVersion, osPlatformId; void init_winver(void) { + static bool initialised = false; + if (initialised) + return; + initialised = true; + OSVERSIONINFO osVersion; static HMODULE kernel32_module; DECL_WINDOWS_FUNCTION(static, BOOL, GetVersionExA, (LPOSVERSIONINFO));