diff options
author | Brad King <brad.king@kitware.com> | 2014-09-26 13:34:26 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2014-09-26 13:34:26 (GMT) |
commit | 208530090dd2707d39f2264b3a7dfe2c0428b583 (patch) | |
tree | ea9eb190258a4f2311796b0f1639731755ab1ff6 /Source/kwsys/ProcessWin32.c | |
parent | 4551a53c119b71473feaa9342d891c098819e8aa (diff) | |
parent | a79ff0e4ed526f8ac0bb8f00201abf3d145fd7dd (diff) | |
download | CMake-208530090dd2707d39f2264b3a7dfe2c0428b583.zip CMake-208530090dd2707d39f2264b3a7dfe2c0428b583.tar.gz CMake-208530090dd2707d39f2264b3a7dfe2c0428b583.tar.bz2 |
Merge branch 'upstream-kwsys' into update-kwsys
Diffstat (limited to 'Source/kwsys/ProcessWin32.c')
-rw-r--r-- | Source/kwsys/ProcessWin32.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/Source/kwsys/ProcessWin32.c b/Source/kwsys/ProcessWin32.c index c8ec754..ef71f26 100644 --- a/Source/kwsys/ProcessWin32.c +++ b/Source/kwsys/ProcessWin32.c @@ -36,6 +36,9 @@ a UNIX-style select system call. #pragma warning (push, 1) #endif #include <windows.h> /* Windows API */ +#if defined(_MSC_VER) && _MSC_VER >= 1800 +# define KWSYS_WINDOWS_DEPRECATED_GetVersionEx +#endif #include <string.h> /* strlen, strdup */ #include <stdio.h> /* sprintf */ #include <io.h> /* _unlink */ @@ -335,7 +338,14 @@ kwsysProcess* kwsysProcess_New(void) windows. */ ZeroMemory(&osv, sizeof(osv)); osv.dwOSVersionInfoSize = sizeof(osv); +#ifdef KWSYS_WINDOWS_DEPRECATED_GetVersionEx +# pragma warning (push) +# pragma warning (disable:4996) +#endif GetVersionEx(&osv); +#ifdef KWSYS_WINDOWS_DEPRECATED_GetVersionEx +# pragma warning (pop) +#endif if(osv.dwPlatformId == VER_PLATFORM_WIN32_WINDOWS) { /* Win9x no longer supported. */ @@ -2370,7 +2380,14 @@ static kwsysProcess_List* kwsysProcess_List_New(void) /* Select an implementation. */ ZeroMemory(&osv, sizeof(osv)); osv.dwOSVersionInfoSize = sizeof(osv); +#ifdef KWSYS_WINDOWS_DEPRECATED_GetVersionEx +# pragma warning (push) +# pragma warning (disable:4996) +#endif GetVersionEx(&osv); +#ifdef KWSYS_WINDOWS_DEPRECATED_GetVersionEx +# pragma warning (pop) +#endif self->NT4 = (osv.dwPlatformId == VER_PLATFORM_WIN32_NT && osv.dwMajorVersion < 5)? 1:0; |