Skip to content

Commit

Permalink
FIX: disable GetVersionEx deprecation warning in VS
Browse files Browse the repository at this point in the history
  • Loading branch information
Oldes committed Mar 9, 2019
1 parent 4018c5e commit faf6715
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/os/win32/host-window.c
Original file line number Diff line number Diff line change
Expand Up @@ -1358,8 +1358,11 @@ static REBCNT Get_Widget_Text(HWND widget, REBVAL *text);

// Get information about system version
// https://docs.microsoft.com/en-us/windows/desktop/api/winnt/ns-winnt-_osversioninfoa
#pragma warning( push )
#pragma warning(disable: 4996) // GetVersionEx is deprecated!
OSVERSIONINFO vi;
GetVersionEx(&vi);
#pragma warning( pop )

if (
vi.dwMajorVersion >= 10 // Windows10 and newer
Expand Down

0 comments on commit faf6715

Please sign in to comment.